So this is what I did on fresh Debian 11 minimal:
apt install postgresql-13 nginx php7.4 php7.4-fpm php7.4-cli php7.4-common php7.4-curl php7.4-gd php7.4-imap php7.4-intl php7.4-json php7.4-mbstring php7.4-pgsql php7.4-opcache php7.4-readline php7.4-soap php7.4-xml php7.4-zip imagemagick
Edit /etc/php/7.4/fpm/php.ini
:
memory_limit = 512M
max_execution_time = 600
max_input_vars = 1500
post_max_size = 10M
upload_max_filesize = 10M
Edit /etc/php/7.5/fpm/pool.d/www.conf
:
upload_max_filesize = 10M
Create /etc/nginx/sites-enabled/t3test.conf
with the following content:
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
server_name t3test.precisma.com;
set $base /var/www/;
root $base/t3test.precisma.com;
# SSL
ssl_certificate /etc/ssl/certs/ssl-cert-snakeoil.pem;
ssl_certificate_key /etc/ssl/private/ssl-cert-snakeoil.key;
# security
include security.conf;
# index.php
index index.php;
# index.php fallback
location / {
try_files $uri $uri/ /index.php?$query_string;
}
# additional config
include general.conf;
# Compressing resource files will save bandwidth and so improve loading speed especially for users
# with slower internet connections. TYPO3 can compress the .js and .css files for you.
# *) Set $GLOBALS['TYPO3_CONF_VARS']['BE']['compressionLevel'] = 9 for the Backend
# *) Set $GLOBALS['TYPO3_CONF_VARS']['FE']['compressionLevel'] = 9 together with the TypoScript properties
# config.compressJs and config.compressCss for GZIP compression of Frontend JS and CSS files.
location ~ \.js\.gzip$ {
add_header Content-Encoding gzip;
gzip off;
types { text/javascript gzip; }
}
location ~ \.css\.gzip$ {
add_header Content-Encoding gzip;
gzip off;
types { text/css gzip; }
}
# TYPO3 - Rule for versioned static files, configured through:
# - $GLOBALS['TYPO3_CONF_VARS']['BE']['versionNumberInFilename']
# - $GLOBALS['TYPO3_CONF_VARS']['FE']['versionNumberInFilename']
if (!-e $request_filename) {
rewrite ^/(.+)\.(\d+)\.(php|js|css|png|jpg|gif|gzip)$ /$1.$3 last;
}
# TYPO3 - Block access to composer files
location ~* composer\.(?:json|lock) {
deny all;
}
# TYPO3 - Block access to flexform files
location ~* flexform[^.]*\.xml {
deny all;
}
# TYPO3 - Block access to language files
location ~* locallang[^.]*\.(?:xml|xlf)$ {
deny all;
}
# TYPO3 - Block access to static typoscript files
location ~* ext_conf_template\.txt|ext_typoscript_constants\.txt|ext_typoscript_setup\.txt {
deny all;
}
# TYPO3 - Block access to miscellaneous protected files
location ~* /.*\.(?:bak|co?nf|cfg|ya?ml|ts|typoscript|tsconfig|dist|fla|in[ci]|log|sh|sql|sqlite)$ {
deny all;
}
# TYPO3 - Block access to recycler and temporary directories
location ~ _(?:recycler|temp)_/ {
deny all;
}
# TYPO3 - Block access to configuration files stored in fileadmin
location ~ fileadmin/(?:templates)/.*\.(?:txt|ts|typoscript)$ {
deny all;
}
# TYPO3 - Block access to libraries, source and temporary compiled data
location ~ ^(?:vendor|typo3_src|typo3temp/var) {
deny all;
}
# TYPO3 - Block access to protected extension directories
location ~ (?:typo3conf/ext|typo3/sysext|typo3/ext)/[^/]+/(?:Configuration|Resources/Private|Tests?|Documentation|docs?)/ {
deny all;
}
location = /typo3 {
rewrite ^ /typo3/;
}
location /typo3/ {
absolute_redirect off;
try_files $uri /typo3/index.php$is_args$args;
}
# handle .php
location ~ [^/]\.php(/|$) {
fastcgi_split_path_info ^(.+?\.php)(/.*)$;
if (!-f $document_root$fastcgi_script_name) {
return 404;
}
# this is the PHP-FPM upstream - see also: https://www.nginx.com/resources/wiki/start/topics/examples/phpfcgi/#connecting-nginx-to-php-fpm
fastcgi_read_timeout 500;
fastcgi_pass unix:/var/run/php/php7.4-fpm.sock;
include php_fastcgi.conf;
}
}
# HTTP redirect
server {
listen 80;
listen [::]:80;
server_name t3test.precisma.com;
include letsencrypt.conf;
location / {
return 301 https://t3test.precisma.com$request_uri;
}
}
Full nginx config attached.
Then I restart all services:
systemctl restart php7.4-fpm.service nginx.service postgresql.service
Adding postgres user and database:
root@t3test:~# sudo -u postgres psql
could not change directory to "/root": Keine Berechtigung
psql (13.5 (Debian 13.5-0+deb11u1))
Type "help" for help.
postgres=# CREATE USER t3test WITH PASSWORD 't3testpassword';
CREATE ROLE
postgres=# CREATE DATABASE t3test WITH OWNER t3test;
CREATE DATABASE
postgres=# GRANT ALL ON DATABASE t3test TO t3test;
GRANT
postgres=# \q
Create the Documentroot and where the TYPO3 source goes:
root@t3test:/var/www# mkdir -p /var/www/t3test.precisma.com
root@t3test:/var/www# mkdir -p /var/www/typo3
Download and extract TYPO3:
root@t3test:/var/www/typo3# wget --content-disposition https://get.typo3.org/10.4.25
root@t3test:/var/www/typo3# tar xzf typo3_src-10.4.25.tar.gz
Create symlinks from Documentroot to TYPO3 Source:
root@t3test:/var/www/t3test.precisma.com# chown www-data:www-data /var/www/t3test.precisma.com/
root@t3test:/var/www/t3test.precisma.com# ln -s ../typo3/typo3_src-10.4.25/ typo3_src
root@t3test:/var/www/t3test.precisma.com# ln -s typo3_src/index.php
root@t3test:/var/www/t3test.precisma.com# ln -s typo3_src/typo3/
root@t3test:/var/www/t3test.precisma.com# ls -la
insgesamt 8
drwxr-xr-x 2 www-data www-data 4096 22. Feb 10:58 .
drwxr-xr-x 6 root root 4096 22. Feb 10:54 ..
lrwxrwxrwx 1 root root 19 22. Feb 10:57 index.php -> typo3_src/index.php
lrwxrwxrwx 1 root root 16 22. Feb 10:58 typo3 -> typo3_src/typo3/
lrwxrwxrwx 1 root root 26 22. Feb 10:57 typo3_src -> ../typo3/typo3_src-10.4.25/
Then open Firefox and Start the installation.
Then root@t3test:/var/www/t3test.precisma.com# touch FIRST_INSTALL
Step 1 works fine:
Step 2 not working:
This is what the Documentroot looks then:
root@t3test:/var/www/t3test.precisma.com# ls -la
insgesamt 20
drwxr-xr-x 5 www-data www-data 4096 22. Feb 11:03 .
drwxr-xr-x 6 root root 4096 22. Feb 10:54 ..
drwxrwsr-x 4 www-data www-data 4096 22. Feb 11:03 fileadmin
-rw-r--r-- 1 root root 0 22. Feb 11:03 FIRST_INSTALL
lrwxrwxrwx 1 root root 19 22. Feb 10:57 index.php -> typo3_src/index.php
lrwxrwxrwx 1 root root 16 22. Feb 10:58 typo3 -> typo3_src/typo3/
drwxrwsr-x 5 www-data www-data 4096 22. Feb 11:03 typo3conf
lrwxrwxrwx 1 root root 26 22. Feb 11:01 typo3_src -> ../typo3/typo3_src-10.4.25
drwxrwsr-x 4 www-data www-data 4096 22. Feb 11:03 typo3temp
and
root@t3test:/var/www/t3test.precisma.com/typo3conf# ls -la
insgesamt 28
drwxrwsr-x 5 www-data www-data 4096 22. Feb 11:03 .
drwxr-xr-x 5 www-data www-data 4096 22. Feb 11:03 ..
drwxrwsr-x 2 www-data www-data 4096 22. Feb 11:03 ext
drwxrwsr-x 2 www-data www-data 4096 22. Feb 11:03 l10n
-rw-rw-r-- 1 www-data www-data 1239 22. Feb 11:03 LocalConfiguration.php
-rw-rw-r-- 1 www-data www-data 3010 22. Feb 11:03 PackageStates.php
drwxrwsr-x 2 www-data www-data 4096 22. Feb 11:03 sites
I attached the complete Documentroot as tgz.
The nginx logs:
root@t3test:/var/www/logs/nginx# cat access.log
192.168.1.175 - - [22/Feb/2022:10:59:32 +0100] "GET / HTTP/1.1" 301 162 "-" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:10:59:36 +0100] "GET / HTTP/2.0" 302 0 "-" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:10:59:36 +0100] "GET /typo3/install.php HTTP/2.0" 200 567 "-" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:10:59:36 +0100] "GET /typo3/install.php?install[action]=mainLayout HTTP/2.0" 200 333 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:10:59:36 +0100] "GET /typo3/install.php?install[action]=checkInstallerAvailable HTTP/2.0" 200 37 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:10:59:36 +0100] "GET /typo3/install.php?install[action]=showInstallerNotAvailable HTTP/2.0" 200 379 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:02:21 +0100] "GET / HTTP/2.0" 302 0 "-" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:02:21 +0100] "GET /typo3/install.php HTTP/2.0" 200 523 "-" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:02:22 +0100] "GET /typo3/install.php?install[action]=mainLayout HTTP/2.0" 200 331 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:02:22 +0100] "GET /typo3/install.php?install[action]=checkInstallerAvailable HTTP/2.0" 200 37 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:02:22 +0100] "GET /typo3/install.php?install[action]=showInstallerNotAvailable HTTP/2.0" 200 379 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:36 +0100] "GET /typo3/install.php HTTP/2.0" 200 523 "-" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:37 +0100] "GET /typo3/install.php?install[action]=mainLayout HTTP/2.0" 200 331 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:37 +0100] "GET /typo3/install.php?install[action]=checkInstallerAvailable HTTP/2.0" 200 36 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:37 +0100] "GET /typo3/install.php?install[action]=checkEnvironmentAndFolders HTTP/2.0" 200 37 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:37 +0100] "GET /typo3/install.php?install[action]=showEnvironmentAndFolders HTTP/2.0" 200 524 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:57 +0100] "GET /typo3/install.php?install[action]=executeEnvironmentAndFolders HTTP/2.0" 200 36 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:57 +0100] "GET /typo3/install.php?install[action]=checkTrustedHostsPattern HTTP/2.0" 200 36 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:57 +0100] "GET /typo3/install.php?install[action]=executeSilentConfigurationUpdate HTTP/2.0" 200 37 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:57 +0100] "GET /typo3/install.php?install[action]=executeSilentConfigurationUpdate HTTP/2.0" 200 36 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
192.168.1.175 - - [22/Feb/2022:11:03:57 +0100] "GET /typo3/install.php?install[action]=checkDatabaseConnect HTTP/2.0" 500 0 "https://t3test.precisma.com/typo3/install.php" "Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:97.0) Gecko/20100101 Firefox/97.0"
root@t3test:/var/www/logs/nginx# cat error.log
2022/02/22 11:03:57 [error] 18799#18799: *4 FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught Error: Call to undefined function mysqli_init() in /var/www/typo3/typo3_src-10.4.25/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/Mysqli/MysqliConnection.php:64
Stack trace:
#0 /var/www/typo3/typo3_src-10.4.25/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/Mysqli/Driver.php(16): Doctrine\DBAL\Driver\Mysqli\MysqliConnection->__construct()
#1 /var/www/typo3/typo3_src-10.4.25/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(362): Doctrine\DBAL\Driver\Mysqli\Driver->connect()
#2 /var/www/typo3/typo3_src-10.4.25/typo3/sysext/core/Classes/Database/Connection.php(101): Doctrine\DBAL\Connection->connect()
#3 /var/www/typo3/typo3_src-10.4.25/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(428): TYPO3\CMS\Core\Database\Connection->connect()
#4 /var/www/typo3/typo3_src-10.4.25/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(388): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#5 /var/www/typo3/typo3_src-10.4.25/vendor/doctrine/dbal/lib/Doctrine/" while reading response header from upstream, client: 192.168.1.175, server: t3test.precisma.com, request: "GET /typo3/install.php?install[action]=checkDatabaseConnect HTTP/2.0", upstream: "fastcgi://unix:/var/run/php/php7.4-fpm.sock:", host: "t3test.precisma.com", referrer: "https://t3test.precisma.com/typo3/install.php"
And the Firefox Console:
I hope this is reproduceable eith this information.