chore: fix dockerfiles and add examples (#3223)

This commit is contained in:
Alexis Saettler
2019-11-20 18:55:02 +01:00
committed by GitHub
parent 24bd12b76d
commit ccdafb865d
32 changed files with 1057 additions and 190 deletions
@@ -0,0 +1,4 @@
FROM monicahq/monicahq:php-apache
COPY supervisord.conf /etc/supervisord.conf
CMD ["supervisord", "-c /etc/supervisord.conf"]
@@ -0,0 +1,30 @@
[supervisord]
nodaemon=true
user=root
[program:cron]
command=/usr/sbin/cron -f -L 0
autostart=true
autorestart=true
[program:queue]
process_name=%(program_name)s_%(process_num)02d
command=/usr/bin/php /var/www/monica/artisan queue:work --sleep=10 --timeout=0 --tries=3 --queue=default,migration
numprocs=1
stdout_logfile=/proc/1/fd/1
stdout_logfile_maxbytes=0
stderr_logfile=/proc/1/fd/2
stderr_logfile_maxbytes=0
autostart=true
autorestart=true
startretries=0
[program:apache]
process_name=%(program_name)s_%(process_num)02d
command=/usr/local/bin/apache2-foreground
stdout_logfile=/proc/1/fd/1
stdout_logfile_maxbytes=0
stderr_logfile=/proc/1/fd/2
stderr_logfile_maxbytes=0
autostart=true
autorestart=true
@@ -0,0 +1,33 @@
version: "3.4"
services:
app:
build: ./app
depends_on:
- db
env_file: .env
ports:
- 80:80
volumes:
- data:/var/www/monica/storage
- www:/var/www/monica
restart: always
db:
image: mysql:5.7
environment:
- MYSQL_ROOT_PASSWORD=sekret_root_password
- MYSQL_DATABASE=monica
- MYSQL_USER=homestead
- MYSQL_PASSWORD=secret
volumes:
- mysql:/var/lib/mysql
restart: always
volumes:
data:
name: data
www:
name: www
mysql:
name: mysql