Here is the yml file:
version: "2"
services:
nextcloud:
image: ghcr.io/linuxserver/nextcloud
container_name: nextcloud
environment:
- PUID=1000 #change PUID if needed
- PGID=100 #change PGID if needed
- TZ=Europe/Amsterdam
volumes:
- /srv/dev-disk-by-label-DockerDisk/docker/appdata/nextcloud/config:/config
- /srv/dev-disk-by-label-DockerDisk/docker/appdata/nextcloud/data:/data
depends_on:
- mariadb
# ports: # uncomment this and the next line if you want to bypass the proxy
# - 450:443
restart: unless-stopped
mariadb:
image: ghcr.io/linuxserver/mariadb
container_name: nextclouddb
environment:
- PUID=1000 #change PUID if needed
- PGID=100 #change PGID if needed
- MYSQL_ROOT_PASSWORD=***************** #change password
- TZ=Europe/Amsterdam
volumes:
- /srv/dev-disk-by-label-DockerDisk/docker/appdata/nextclouddb:/config #/srv/dev-disk-by-label-disk1 needs to be adjusted
restart: unless-stopped
swag:
image: ghcr.io/linuxserver/swag #uncomment this line and comment the previous one if you want to use the new swag container (see link at bottom of the post)
container_name: swag
cap_add:
- NET_ADMIN
environment:
- PUID=1000 #change PUID if needed
- PGID=100 #change PGID if needed
- TZ=Europe/Amsterdam
- URL=**************.net
- SUBDOMAINS=www,
- VALIDATION=http
- CERTPROVIDER=zerossl
- EMAIL=****************.nl
volumes:
- /srv/dev-disk-by-label-DockerDisk/docker/appdata/swag:/config
ports:
- 443:443
- 80:80
restart: unless-stopped
Had the ports at 81:80 and 444:443 before, but no difference. Went over this several times, and before swag change was running well over a year.