psi-4ward / docker-contao

Docker Container for Contao CMS
5 stars 0 forks source link
contao contao-cms docker docker-container

Contao Docker Container

Image Size Docker Stars Docker Pulls Docker Automated buil

Usage

// Start MySQL/MariaDB first
sudo docker run --rm --name mysql \
  -e MYSQL_ROOT_PASSWORD=root \
  -v $HOME/contao/_db:/var/lib/mysql \
  mariadb

// take contao installation from $HOME/contao/contao
sudo docker run --rm --name contao \
  -v $HOME/contao/contao:/var/www \
  --link mysql:mysql \
  -p 80:80 \
  -e RUN_UID=$UID \
  -e XDEBUG=true \
  -e PHP_VALUE=max_execution_time=90,memory_limit=512M \
  psitrax/contao

// enter the Container
sudo docker exec -ti contao bash
root at 53e71dbf4adc in ~ su apache
apache at 53e71dbf4adc in /var/www ~ composer create-project contao/standard-edition website

// if permission problems occour change owner
root at 53e71dbf4adc in ~ chown -R apache /var/www

// or managed edition
apache at 53e71dbf4adc in /var/www ~ composer create-project contao/managed-edition website

apache at 53e71dbf4adc in /var/www ~ mv website/* website/.gitignore .
// Restart Container to detect Contao 4

Configuration

Use Environment Variables for Configuration

Maintainer