Last active
May 20, 2018 20:52
-
-
Save awade/95be5f7a5c744c8c77544e81b7ae32c5 to your computer and use it in GitHub Desktop.
Nextcloud docker compose with exposed port, works with jwilder/nginx-proxy and jrcs/letsencrypt-nginx-proxy-companion for SSL/TLS secure access.
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
version: '2' | |
volumes: | |
nextcloud: | |
nextcloudDB: | |
services: | |
db: | |
image: mariadb | |
restart: always | |
volumes: | |
- nextcloudDB:/var/lib/mysql | |
environment: | |
- MYSQL_ROOT_PASSWORD=<really secure pass> | |
- MYSQL_PASSWORD=<database password> | |
- MYSQL_DATABASE=nextcloud | |
- MYSQL_USER=nextcloud | |
network_mode: bridge | |
app: | |
image: nextcloud | |
links: | |
- db | |
ports: | |
- 8080:80 | |
volumes: | |
- nextcloud:/var/www/html | |
environment: | |
- VIRTUAL_HOST=nextcloud.example.com | |
- LETSENCRYPT_HOST=nextcloud.example.com | |
- MYSQL_HOST=db | |
depends_on: | |
- db | |
network_mode: bridge | |
restart: always |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment