Sign inSign up

pascal20997/typo3

By pascal20997

Updated almost 5 years ago

TYPO3 docker container that provides a basic apache2 setup with TYPO3 7/8/9 in composer mode.

Image
1

50K+

pascal20997/typo3 repository overview

TYPO3 docker container (TYPO3 7, TYPO3 8, TYPO3 9)

Container by crynton.com

Master git repository: https://git.crynton.com/docker/typo3

Contact: Create an issue ticket if you´ve a feature request, bug, and other with this container development related questions OR use https://crynton.com/contact.html for any other question :)

Settings

You can configure this docker container by using the following environment variables:

Variable nameDescriptionDefault
TYPO3_VERSIONThe version which should be used for installing TYPO3 via composer^9
SERVER_ADMINE-Mail of the server admin (for apache)[email protected]
SURF_DOWNLOAD_URLDownload-URL to be used for installing surfDownload URL for surf 2.0.0-beta7
DOCUMENT_ROOTDocument root folder/home/crynton/htdocs/public (create-project default)
INSTALL_TYPO3Set to a different value then true to not install TYPO3 with first boottrue
START_SSHDSet to a different value then true to not start openssh-server on boottrue
REVERSE_PROXY_SETTINGSEnable settings for reverse proxy usage. This will fix wrong ip addresses in the apache logfalse 

Examples

Using TYPO3 with MariaDB
version: '3'
services:
  apache_t3-9:
    image: pascal20997/typo3:latest
    container_name: apache_t3-9
    restart: always
    ports:
      - 8080:80
    volumes:
      - htdocs:/home/crynton/htdocs
      - ssh:/root/.ssh
      - /etc/localtime:/etc/localtime:ro
    environment:
      SERVER_ADMIN: "[email protected]"
    depends_on:
      - db_t3-9
  db_t3-9:
    image: mariadb:10
    volumes:
      - db_data:/var/lib/mysql
    environment:
      - "MYSQL_ROOT_PASSWORD=MySecretPassword"
      - "MYSQL_DATABASE=typo3"
      - "MYSQL_USER=typo3"
      - "MYSQL_PASSWORD=123456789"
volumes:
  htdocs:
  ssh:
  db_data:
Using TYPO3 with MariaDB and jwilder/nginx-proxy
version: '3'
services:
  apache_t3-9:
    image: pascal20997/typo3:latest
    container_name: apache_t3-9
    restart: always
    volumes:
      - htdocs:/home/crynton/htdocs
      - ssh:/root/.ssh
      - /etc/localtime:/etc/localtime:ro
    environment:
      DEFAULT_HOST: "domain.tld"
      VIRTUAL_HOST: "domain.tld"
      LETSENCRYPT_HOST: "domain.tld"
      LETSENCRYPT_EMAIL: "[email protected]"
      SERVER_ADMIN: "[email protected]"
      SSL_POLICY: "Mozilla-Modern"
    depends_on:
      - db_t3-9
    networks:
      - proxy-prod
  db_t3-9:
    image: mariadb:10
    volumes:
      - db_data:/var/lib/mysql
    environment:
      - "MYSQL_ROOT_PASSWORD=MySecretPassword"
      - "MYSQL_DATABASE=typo3"
      - "MYSQL_USER=typo3"
      - "MYSQL_PASSWORD=123456789"
    networks:
      - proxy-prod
volumes:
  htdocs:
  ssh:
  db_data:
networks:
  proxy-prod:
    external:
      name: nginx-proxy
Using TYPO3 with PostgreSQL
version: '3'
services:
  apache_t3-9:
    image: pascal20997/typo3:latest
    container_name: apache_t3-9
    restart: always
    ports:
      - 8080:80
    volumes:
      - htdocs:/home/crynton/htdocs
      - ssh:/root/.ssh
      - /etc/localtime:/etc/localtime:ro
    environment:
      SERVER_ADMIN: "[email protected]"
    depends_on:
      - db_t3-9
  db_t3-9:
    image: postgres:latest
    volumes:
      - db_data:/var/lib/postgresql/data
    environment:
      - "POSTGRES_USER=typo3"
      - "POSTGRES_PASSWORD=MySecretPassword"
volumes:
  htdocs:
  ssh:
  db_data:
Using those examples on macOS

It may be slow but you can use it. In my test environment I had to remove the /etc/localtime mount from the example and replace the volumes with a local mount.

version: '3'
services:
  apache_t3-9:
    image: pascal20997/typo3:latest
    container_name: apache_t3-9
    restart: always
    ports:
      - 8080:80
    volumes:
      - ./data/htdocs:/home/crynton/htdocs
      - ./data/ssh:/root/.ssh
    environment:
      SERVER_ADMIN: "[email protected]"
    depends_on:
      - db_t3-9
  db_t3-9:
    image: mariadb:10
    volumes:
      - ./data/db:/var/lib/mysql
    environment:
      - "MYSQL_ROOT_PASSWORD=MySecretPassword"
      - "MYSQL_DATABASE=typo3"
      - "MYSQL_USER=typo3"
      - "MYSQL_PASSWORD=123456789"

FAQ

What is the hostname for MySQL?

The hostname is the name of your container. In my examples it´s db_t3. You should use that hostname while installing TYPO3.

Is this container working with TYPO3 lower 7.6?

Not official. You can try using older versions than TYPO3 7.6 but I´ll not support those versions officially.

Tag summary

Content type

Image

Digest

Size

233.3 MB

Last updated

almost 5 years ago

docker pull pascal20997/typo3