Answer the question
In order to leave comments, you need to log in
How to build gitea in docker swarm?
Good afternoon, colleagues.
Tell me how to raise gitea in docker swarm? I am just starting to understand docker and docker swarm in particular, so I obviously make mistakes.
Wrote docker-compose with the following content:
version: '3.7'
networks:
gitea-net:
driver: overlay
attachable: true
volumes:
data: {}
mysql: {}
services:
gitea:
image: 'gitea/gitea:1.9.0'
volumes:
- './gitea/data:/data'
ports:
- '3300:3000'
- '3322:22'
depends_on:
- db
restart: always
networks:
- gitea-net
deploy:
mode: replicated
replicas: 1
placement:
constraints:
- 'node.role == manager'
db:
image: 'mariadb:10'
volumes:
- './gitea/mysql:/data'
environment:
- MYSQL_ROOT_PASSWORD=changeme
- MYSQL_DATABASE=gitea
- MYSQL_USER=gitea
- MYSQL_PASSWORD=changeme
restart: always
networks:
- gitea-net
deploy:
mode: global
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question