Created
March 6, 2016 21:46
-
-
Save karelbemelmans/7b3ef04034955506102d to your computer and use it in GitHub Desktop.
A Docker compose file to create a Drupal 8 with MySQL stack, useable for local development.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Basicly taken from: | |
# https://github.com/docker-library/drupal/issues/3#issuecomment-153775540 | |
# | |
# Volume containers are the way to go. | |
version: '2' | |
services: | |
drupal: | |
image: drupal:8 | |
links: | |
- "db:mysql" | |
ports: | |
- "80:80" | |
volumes: | |
- storage-drupal:/var/www/html/modules | |
- storage-drupal:/var/www/html/profiles | |
- storage-drupal:/var/www/html/themes | |
- storage-drupal:/var/www/html/sites | |
db: | |
image: mysql | |
volumes: | |
- storage-mysql:/var/lib/mysql | |
environment: | |
- MYSQL_USER=db_user | |
- MYSQL_PASSWORD=db_pass | |
- MYSQL_DATABASE=drupal8 | |
- MYSQL_ROOT_PASSWORD=db_root_pass | |
volumes: | |
storage-drupal: | |
driver: local | |
storage-mysql: | |
driver: local |
I used the same yml file so tell me what will be the output? my file is getting struck and not running for long time so i had to cancel it.
I created this 4 years ago, safe to assume lots of things have changed in the Drupal 8 image for this to stop working.
I'm not updating this anymore so you're on your own here I'm afraid.
I used the same yml file so tell me what will be the output? my file is getting struck and not running for long time so i had to cancel it
output:
Hi, have you been able to run it?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I used the same yml file so tell me what will be the output? my file is getting struck and not running for long time so i had to cancel it
output:
$ docker-compose up
Creating network "testing_default" with the default driver
Creating volume "testing_storage-drupal" with local driver
Creating volume "testing_storage-mysql" with local driver
Creating testing_db_1 ... done
Creating testing_drupal_1 ... done
Attaching to testing_db_1, testing_drupal_1
db_1 | 2020-03-04 13:37:54+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.19-1debian9 started.
db_1 | 2020-03-04 13:37:56+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
db_1 | 2020-03-04 13:37:57+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.19-1debian9 started.
db_1 | 2020-03-04 13:37:57+00:00 [Note] [Entrypoint]: Initializing database files
db_1 | 2020-03-04T13:37:57.374255Z 0 [Warning] [MY-011070] [Server] 'Disabling symbolic links using --skip-symbolic-links (or equivalent) is the default. Consider not using this option as it' is deprecated and will be removed in a future release.
db_1 | 2020-03-04T13:37:57.374746Z 0 [System] [MY-013169] [Server] /usr/sbin/mysqld (mysqld 8.0.19) initializing of server in progress as process 44
drupal_1 | AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.19.0.3. Set the 'ServerName' directive globally to suppress this message
drupal_1 | AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.19.0.3. Set the 'ServerName' directive globally to suppress this message
drupal_1 | [Wed Mar 04 13:38:00.666210 2020] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.25 (Debian) PHP/7.3.15 configured -- resuming normal operations
drupal_1 | [Wed Mar 04 13:38:00.666516 2020] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
db_1 | 2020-03-04T13:38:03.820534Z 5 [Warning] [MY-010453] [Server] root@localhost is created with an empty password ! Please consider switching off the --initialize-insecure option.
db_1 | 2020-03-04 13:38:09+00:00 [Note] [Entrypoint]: Database files initialized
db_1 | 2020-03-04 13:38:09+00:00 [Note] [Entrypoint]: Starting temporary server
db_1 | 2020-03-04T13:38:09.575710Z 0 [Warning] [MY-011070] [Server] 'Disabling symbolic links using --skip-symbolic-links (or equivalent) is the default. Consider not using this option as it' is deprecated and will be removed in a future release.
db_1 | 2020-03-04T13:38:09.575896Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.19) starting as process 94
db_1 | 2020-03-04T13:38:11.203615Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
db_1 | 2020-03-04T13:38:11.223216Z 0 [Warning] [MY-011810] [Server] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
db_1 | 2020-03-04T13:38:11.255498Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.0.19' socket: '/var/run/mysqld/mysqld.sock' port: 0 MySQL Community Server - GPL.
db_1 | 2020-03-04 13:38:11+00:00 [Note] [Entrypoint]: Temporary server started.
db_1 | 2020-03-04T13:38:11.499830Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Socket: '/var/run/mysqld/mysqlx.sock'
db_1 | Warning: Unable to load '/usr/share/zoneinfo/iso3166.tab' as time zone. Skipping it.
db_1 | Warning: Unable to load '/usr/share/zoneinfo/leap-seconds.list' as time zone. Skipping it.
db_1 | Warning: Unable to load '/usr/share/zoneinfo/zone.tab' as time zone. Skipping it.
db_1 | Warning: Unable to load '/usr/share/zoneinfo/zone1970.tab' as time zone. Skipping it.
db_1 | 2020-03-04 13:38:20+00:00 [Note] [Entrypoint]: Creating database drupal8
db_1 | 2020-03-04 13:38:20+00:00 [Note] [Entrypoint]: Creating user db_user
db_1 | 2020-03-04 13:38:20+00:00 [Note] [Entrypoint]: Giving user db_user access to schema drupal8
db_1 |
db_1 | 2020-03-04 13:38:20+00:00 [Note] [Entrypoint]: Stopping temporary server
db_1 | 2020-03-04T13:38:20.656922Z 14 [System] [MY-013172] [Server] Received SHUTDOWN from user root. Shutting down mysqld (Version: 8.0.19).
db_1 | 2020-03-04T13:38:23.632668Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.19) MySQL Community Server - GPL.
db_1 | 2020-03-04 13:38:23+00:00 [Note] [Entrypoint]: Temporary server stopped
db_1 |
db_1 | 2020-03-04 13:38:23+00:00 [Note] [Entrypoint]: MySQL init process done. Ready for start up.
db_1 |
db_1 | 2020-03-04T13:38:24.104491Z 0 [Warning] [MY-011070] [Server] 'Disabling symbolic links using --skip-symbolic-links (or equivalent) is the default. Consider not using this option as it' is deprecated and will be removed in a future release.
db_1 | 2020-03-04T13:38:24.104821Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.19) starting as process 1
db_1 | 2020-03-04T13:38:26.091327Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
db_1 | 2020-03-04T13:38:26.097464Z 0 [Warning] [MY-011810] [Server] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
db_1 | 2020-03-04T13:38:26.135430Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.0.19' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server - GPL.
db_1 | 2020-03-04T13:38:26.188736Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Socket: '/var/run/mysqld/mysqlx.sock' bind-address: '::' port: 33060