Skip to content

Instantly share code, notes, and snippets.

@si294r
Created December 21, 2017 04:57
Show Gist options
  • Save si294r/0e99f4ba239534ce0c4ccac73df28062 to your computer and use it in GitHub Desktop.
Save si294r/0e99f4ba239534ce0c4ccac73df28062 to your computer and use it in GitHub Desktop.

docker

mariadb

docker create --name mariadb -e MYSQL_ROOT_PASSWORD=password -p 3306:3306 mariadb:10.2

docker start mariadb

docker exec -it mariadb /bin/bash

php 7 - apache

docker create --name php7-apache -p 80:80 php:7-apache

docker start php7-apache

docker exec -ti php7-apache /bin/bash

docker logs -f —tail 100 php7-apache

docker-php-ext-install pdo_mysql

docker create --name php7-apache -v /root/docker/php7-apache:/hostdir -p 82:80 php:7-apache

php 5 - apache

docker create --name php5-apache -p 81:80 php:5-apache

docker start php5-apache

docker exec -ti php5-apache /bin/bash

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment