Skip to content

Instantly share code, notes, and snippets.

@gOOvER
Created September 17, 2023 08:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gOOvER/497e4445f5267fcbf3ec2cd46f1b138d to your computer and use it in GitHub Desktop.
Save gOOvER/497e4445f5267fcbf3ec2cd46f1b138d to your computer and use it in GitHub Desktop.
dockercompose wordpress php8.2
version: '3.1'
services:
wordpress:
image: wordpress:php8.2
restart: unless-stopped
container_name: wordpress
environment:
WORDPRESS_DB_HOST: wordpress-db
WORDPRESS_DB_USER: wordpress ## Hier Benutzer eingeben ##
WORDPRESS_DB_PASSWORD: wordpress ## Hier Passwort eingeben ##
WORDPRESS_DB_NAME: wordpress
volumes:
- ./app:/var/www/html
- ./wordpress.ini:/usr/local/etc/php/conf.d/wordpress.ini
labels:
- "traefik.enable=true"
- "traefik.http.routers.wordpress.entrypoints=websecure"
- "traefik.http.routers.wordpress.rule=Host(`www.deinedomain.de`,`deinedomain.de`)"
- "traefik.http.routers.wordpress.middlewares=default@file"
- "traefik.http.routers.wordpress.tls=true"
- "traefik.http.routers.wordpress.tls.certresolver=http_resolver"
- "traefik.http.routers.wordpress.service=wordpress"
- "traefik.http.services.wordpress.loadbalancer.server.port=80"
- "traefik.docker.network=proxy"
networks:
- proxy
- default
- crowdsec
wordpress-db:
image: mariadb:11.1-jammy
container_name: wordpress-db
restart: unless-stopped
environment:
MYSQL_DATABASE: wordpress
MYSQL_USER: wordpress
MYSQL_PASSWORD: wordpress
MYSQL_RANDOM_ROOT_PASSWORD: '1'
volumes:
- ./database:/var/lib/mysql
networks:
- default
wordpress-redis:
image: redis:alpine
container_name: wordpress-redis
restart: unless-stopped
networks:
- default
networks:
proxy:
external: true
crowdsec:
external: true
file_uploads = On
memory_limit = 256M
upload_max_filesize = 64M
post_max_size = 64M
max_execution_time = 300
max_input_time = 1000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment