82 lines
2.1 KiB
Plaintext
82 lines
2.1 KiB
Plaintext
|
---
|
||
|
version: "{{ omni_compose_version | string }}"
|
||
|
|
||
|
|
||
|
networks:
|
||
|
nextcloud:
|
||
|
name: nextcloud
|
||
|
driver: overlay
|
||
|
ipam:
|
||
|
driver: default
|
||
|
config:
|
||
|
- subnet: {{ omni_compose_apps.nextcloud.networks.main }}
|
||
|
|
||
|
|
||
|
volumes:
|
||
|
database:
|
||
|
name: datastore{{ omni_compose_apps.nextcloud.datastore }}/database
|
||
|
driver: glusterfs
|
||
|
data:
|
||
|
name: datastore{{ omni_compose_apps.nextcloud.datastore }}/data
|
||
|
driver: glusterfs
|
||
|
config:
|
||
|
name: datastore{{ omni_compose_apps.nextcloud.datastore }}/config
|
||
|
driver: glusterfs
|
||
|
|
||
|
|
||
|
services:
|
||
|
server:
|
||
|
image: nextcloud:{{ omni_compose_apps.nextcloud.versions.server | default(omni_compose_apps.nextcloud.versions.default) }}
|
||
|
hostname: nextcloud-server
|
||
|
networks:
|
||
|
- nextcloud
|
||
|
ports:
|
||
|
- published: {{ omni_compose_apps.nextcloud.ports.8080 }}
|
||
|
target: 8080
|
||
|
protocol: tcp
|
||
|
mode: ingress
|
||
|
volumes:
|
||
|
- type: volume
|
||
|
source: data
|
||
|
target: /data
|
||
|
read_only: false
|
||
|
- type: volume
|
||
|
source: config
|
||
|
target: /var/www/html
|
||
|
read_only: false
|
||
|
environment:
|
||
|
NEXTCLOUD_DATA_DIR: /data
|
||
|
NEXTCLOUD_ADMIN_USER: admin
|
||
|
NEXTCLOUD_ADMIN_PASSWORD: {{ omni_compose_app_secrets.nextcloud.admin_password }}
|
||
|
MYSQL_DATABASE: nextcloud
|
||
|
MYSQL_USER: root
|
||
|
MYSQL_PASSWORD: {{ omni_compose_app_secrets.nextcloud.database_password }}
|
||
|
MYSQL_HOST: database
|
||
|
REDIS_HOST: cache
|
||
|
deploy:
|
||
|
replicas: 1
|
||
|
|
||
|
database:
|
||
|
image: mariadb:{{ omni_compose_apps.nextcloud.versions.database | default(omni_compose_apps.nextcloud.versions.default) }}
|
||
|
hostname: nextcloud-database
|
||
|
networks:
|
||
|
- nextcloud
|
||
|
volumes:
|
||
|
- type: volume
|
||
|
source: database
|
||
|
target: /var/lib/mysql
|
||
|
read_only: false
|
||
|
environment:
|
||
|
MYSQL_ROOT_PASSWORD: {{ omni_compose_app_secrets.nextcloud.database_password }}
|
||
|
MYSQL_DATABASE: nextcloud
|
||
|
deploy:
|
||
|
replicas: 1
|
||
|
|
||
|
cache:
|
||
|
image: redis:{{ omni_compose_apps.nextcloud.versions.cache | default(omni_compose_apps.nextcloud.versions.default) }}
|
||
|
hostname: nextcloud-cache
|
||
|
networks:
|
||
|
- nextcloud
|
||
|
deploy:
|
||
|
replicas: 1
|