Sign inSign up

netinventors/typo3

By netinventors

•Updated about 22 hours ago

TYPO3 development images

Image
0

7.2K

netinventors/typo3 repository overview

⁠TYPO3 development image

TYPO3 development image based on netinventors/php-base⁠. At the first start TYPO3 is installed automatically, including database, admin user, site configuration, dotenv support, Psalm and Webpack Encore. TYPO3 is set up with vendor/bin/typo3 setup.

⁠Available architectures

  • amd64
  • arm64

⁠Tags

TagContent
<typo3-version>, latestAll PHP versions of the base image, PHP 8.2 is the default
<typo3-version>-php<X.Y>, latest-php<X.Y>Only PHP <X.Y> (smaller image), e.g. 13.4.37-php8.4

Currently maintained is TYPO3 13.4 with PHP 8.2, 8.3, 8.4 and 8.5. 13.4.12 is still built, but has known security issues, use the latest 13.4 release instead. Tags of TYPO3 11.5 are still available, but are no longer updated.

⁠Server services

The versions below refer to the images based on netinventors/php-base 1.5.0.

  • Debian Bookworm (12.15)
  • Apache 2.4.68 (mpm_prefork, mod_php, modules headers, rewrite and ssl enabled)
  • PHP versions (tags without -php<X.Y> suffix)
    • 7.3.33
    • 7.4.33
    • 8.0.30
    • 8.1.34
    • 8.2.35
    • 8.3.36
    • 8.4.27
    • 8.5.12
  • PHP modules
    • amqp
    • apcu (Apache only)
    • curl
    • gd
    • igbinary
    • imagick
    • imap
    • intl
    • mbstring
    • mcrypt
    • memcached
    • msgpack
    • mysql (mysqli, mysqlnd, pdo_mysql)
    • opcache (Apache only)
    • redis
    • soap
    • tidy
    • xdebug (Apache only, see ENABLE_XDEBUG)
    • xml
    • zip
  • AWS CLI 2.39.3
  • Symfony CLI 5.22.2
  • Composer 2.11.1 / 1.10.27
  • Cron Daemon
  • Ghostscript 10.00.0
  • ImageMagick 6.9.11-60 Q16
  • MariaDB 10.11.19 (starts optional)
  • Node.js 24.22.2 (managed by n⁠ 11.0.0)
  • NPM 11.19.1
  • OpenSSH Server
  • Supervisor Daemon 4.2.5

TYPO3 13 requires PHP 8.2 or higher.

⁠TYPO3

The TYPO3 sources are based on typo3/cms-base-distribution with these additional packages:

  • typo3/minimal
  • typo3/cms-adminpanel
  • typo3/cms-filemetadata
  • typo3/cms-impexp
  • typo3/cms-indexed-search
  • typo3/cms-linkvalidator
  • typo3/cms-lowlevel
  • typo3/cms-opendocs
  • typo3/cms-recycler
  • typo3/cms-redirects
  • typo3/cms-reports
  • typo3/cms-scheduler
  • typo3/cms-workspaces
  • fluidtypo3/vhs
  • roave/security-advisories (dev)

⁠Additional packages

  • bat (available as bat alias for the web user)
  • default-mysql-client
  • git
  • iputils-ping
  • joe
  • jq
  • less
  • nano
  • net-tools
  • rsync
  • task 3.54.0
  • tidy
  • unzip
  • vim
  • yq 4.54.1

⁠Ports

PortService
22SSH
80HTTP
443HTTPS (self-signed certificate for localhost)
3306MariaDB
8080Webpack Encore dev-server (not exposed)

Port 8080 has to be published explicitly for task dev-server, e.g. -p 8080:8080.

The container health check requests http://127.0.0.1/ping.

⁠Customizable environment variables

All described environment variables are displayed with their default values.

⁠System
Variable nameDefault value
TZEurope/Berlin
⁠Web user

The web user is created at the first container start. The user belongs to the group www-data, runs Apache, the TYPO3 scheduler and the installation, and can log in via SSH.

Variable nameDefault value
WEB_USER_UID1000
WEB_USER_USERNAME"netinventors"
WEB_USER_PASSWORD"athene"
⁠Permission fixer

At each start the ownership and permissions of the cache, log, backup and local-repository directories are fixed.

Variable nameDefault valuePossible valuesDescription
SKIP_PERMISSION_FIXER"false"
  • true
  • false
Skips the permission fixer completely
SKIP_HTML_PERMISSION_FIXER"true"
  • true
  • false
Skips the ownership fix of /var/www/html
⁠PHP

The currently available PHP versions are:

  • 7.3
  • 7.4
  • 8.0
  • 8.1
  • 8.2
  • 8.3
  • 8.4
  • 8.5

The tags with a -php<X.Y> suffix only contain one PHP version, which is also the default value of PHP_VERSION.

Variable nameDefault valuePossible values
PHP_INI_SCAN_DIR":/usr/local/etc/php/cli/conf.d"
APACHE_PHP_INI_SCAN_DIR":/usr/local/etc/php/apache2/conf.d"
PHP_VERSION8.2
  • 7.3
  • 7.4
  • 8.0
  • 8.1
  • 8.2
  • 8.3
  • 8.4
  • 8.5
ENABLE_XDEBUG"true"
  • true
  • false

The leading : keeps the default scan directory of the PHP version and adds the given directory.

The Apache PHP configuration contains these TYPO3 specific settings:

SettingValue
memory_limit512M
max_execution_time300
max_input_vars1500
post_max_size25M
upload_max_filesize25M
realpath_cache_ttl3600
xdebug.max_nesting_level512
⁠Composer
Variable nameDefault valuePossible values
COMPOSER_HOME/usr/local/share/composer
COMPOSER_VERSION2
  • 1
  • 2
UPDATE_COMPOSER"false"
  • true
  • false

Both versions are available as composer-1 and composer-2, composer links to the selected one.

⁠Node.js / NPM and Node.js module n
Variable nameDefault valuePossible values
NODE_VERSION24.22.2
NPM_VERSION11.19.1
UPDATE_NODE"false"
  • true
  • false
UPDATE_NPM"false"
  • true
  • false
UPDATE_N"false"
  • true
  • false

If NODE_VERSION or NPM_VERSION differs from the preinstalled version, the requested version is installed at container start (internet access required). NODE_VERSION accepts every version n understands, e.g. 22 or lts. The value -1 skips the installation.

⁠TYPO3
Variable nameDefault valuePossible valuesDescription
TYPO3_AUTO_INSTALL"true"
  • true
  • false
Installs TYPO3 at start if install.lock is missing
TYPO3_FORCE_INSTALL"false"
  • true
  • false
Reinstalls TYPO3 at every start, see below
TYPO3_CONTEXT"Development"TYPO3 application context
TYPO3_SITE_URL"https://localhost⁠"Base URL of the site configuration
TYPO3_SITE_NAME"TYPO3-Site"
TYPO3_SITEPACKAGE_NS"netinventors"Identifier of the site configuration and default sitepackage namespace
TYPO3_ADMIN_USERNAME"admin"
TYPO3_ADMIN_PASSSWORD"typo3"Backend admin and install tool password, three "S" in the name
TYPO3_ADMIN_EMAIL"admin@localhost"
PUPPETEER_SKIP_CHROMIUM_DOWNLOAD"true"
  • true
  • false
Puppeteer < 22
PUPPETEER_SKIP_DOWNLOAD"true"
  • true
  • false
Puppeteer >= 19

TYPO3_FORCE_INSTALL="true" drops the database and overwrites the files in /var/www/html at every start. The installation runs at container start. Meanwhile a preview page is shown on port 80 and 443.

⁠MySQL database server

If MYSQL_HOST is localhost or 127.0.0.1 a local MariaDB server instance will be started automatically and the user and database are created during the installation. For an external server the user must already exist.

Variable nameDefault value
MYSQL_HOST"localhost"
MYSQL_PORT"3306"
MYSQL_USER"netinventors"
MYSQL_PASSWORD"athene"
MYSQL_DATABASE"typo3"
MYSQL_DRIVER"pdo_mysql"

⁠Installation steps

The installation can be repeated manually with install-typo3.sh -f as root. If a step fails, the installation is aborted and install.lock is not created, so it is retried at the next start.

StepDescription
start-mysqlStarts the local MariaDB server and waits until it accepts connections
create-mysql-userCreates the database and the user on the local MariaDB server
copy-sourcesCopies the TYPO3 sources to /var/www/html
install-typo3Runs typo3 setup, sets the admin and install tool password, creates the site
install-dotenvInstalls helhum/dotenv-connector, creates .env files and config/system/additional.php
install-psalmInstalls Psalm 6 in dev-ops/psalm (composer psalm, composer test)
install-typo3-encoreInstalls ssch/typo3-encore and Webpack Encore 6 with Stimulus
stop-mysqlStops the MariaDB server, it is started again by supervisor

⁠Sitepackage

task sitepackage:install creates a sitepackage extension in local-repository/sitepackage and installs it via Composer. It provides the site set <namespace>/sitepackage (depends on typo3/fluid-styled-content), which is added to the site configuration. TypoScript records on the root page are deleted, so the TypoScript of the site set is used. Its assets are built with Webpack Encore (task build, task dev-server) and included via typo3_encore.

task sitepackage:install -- -f reinstalls the sitepackage and overwrites all changes in local-repository/sitepackage.

⁠Background processes

Supervisor runs Apache, Cron, the SSH server and, with a local MYSQL_HOST, MariaDB. Cron runs the TYPO3 scheduler (vendor/bin/typo3 scheduler:run) every minute as web user.

⁠Directories

LocationDescription
/var/www/htmlTYPO3 installation, document root is /var/www/html/public
/var/www/html/local-repositoryLocal Composer path repository, e.g. for the sitepackage
/var/www/html/config/systemTYPO3 configuration (settings.php, additional.php)
/usr/local/share/skel.d/typo3TYPO3 sources, copied to /var/www/html during the installation
/usr/local/etc/install.dInstallation steps (*.sh)
/usr/local/share/composerComposer home and cache directory
/usr/local/etc/php/apache2/conf.dAdditional loaded PHP configuring *.ini files for the Apache
/usr/local/etc/php/cli/conf.dAdditional loaded PHP configuring *.ini files for the CLI
/usr/local/etc/boot.dShell scripts (*.sh) executed in sorted order at container start
/usr/local/etc/supervisor/conf.dAdditional supervisor program configurations (*.conf)
/usr/local/share/permission-fixerShell scripts (*.sh) fixing permissions at container start
/usr/local/share/certsCA (ca.pem, trusted in the container) and localhost certificate
/usr/local/var/logDirectory where all the logs go to
/usr/local/var/backupDirectory storing created snapshots

The log directory contains the logs of Apache, MariaDB and supervisor and is linked as ~/log into the home directory of the web user.

⁠Breaking changes

Some mapped volumes will now locate in different places.

Old locationNew location
/certsNo longer required
/etc/ssl/openssl.cnfNo longer required
/etc/apache2/sites-enabledNo longer required
/home/netinventors/.composer/usr/local/share/composer
/usr/local/etc/php/conf.d/usr/local/etc/php/cli/conf.d
/var/log/app/usr/local/var/log

⁠Taskfile

You can run different commands directly via task⁠ in /var/www/html. Executing task without an argument is an alias for task --list and shows the available commands.

⁠Available commands
CommandDescription
install-dependenciesInstalls the npm dependencies of the project and the extensions
sitepackage:installInstalls the sitepackage
Example: task sitepackage:install -- -n netinventors, -f reinstalls it
dev-serverStarts the Webpack Encore dev-server
devBuilds the assets for development
buildBuilds the assets for production
build:fullInstalls the npm dependencies and builds the assets
typo3Runs "vendor/bin/typo3"
Example: task typo3 -- cache:flush
cache:flushClears the cache
extension:setupSets up the extensions (database schema, default data)
snapshot:listLists available snapshots
snapshot:createCreates a snapshot
Example: task snapshot:create -- "Comment"
snapshot:restoreRestores a snapshot
Example: task snapshot:restore -- "810511133700"
snapshot:restore:filesRestores a snapshots files
Example: task snapshot:restore:files -- "810511133700"
snapshot:restore:databaseRestores a snapshots database
Example: task snapshot:restore:database -- "810511133700"
snapshot:removeRemoves a snapshot
Example: task snapshot:remove -- "810511133700"
snapshot:purgePurges all snapshots

Tag summary

Content type

Image

Digest

sha256:4cefd09bc…

Size

628.7 MB

Last updated

about 22 hours ago

docker pull netinventors/typo3