Browse Source

git yaml

master
root Apostolos 5 years ago
parent
commit
4f0d75a8b0
  1. 51
      git.yaml
  2. 1
      git.yaml.sh

51
git.yaml

@ -0,0 +1,51 @@
version: "3.3"
networks:
gitea:
external: false
services:
server:
image: gitea/gitea:1.9
environment:
- USER_UID=1002
- USER_GID=1002
- DB_TYPE=mysql
- DB_HOST=db:3306
- DB_NAME=gitea
- DB_USER=gitea
- DB_PASSWD=gitea
restart: always
networks:
- gitea
volumes:
- /var/lib/gitea:/data
ports:
- "3000:3000"
- "3080:3080"
- "127.0.0.1:2222:22"
depends_on:
- db
deploy:
placement:
constraints:
- node.id == ${REGISTERid}
db:
image: mysql:5.7
restart: always
environment:
- MYSQL_ROOT_PASSWORD=gitea
- MYSQL_USER=gitea
- MYSQL_PASSWORD=gitea
- MYSQL_DATABASE=gitea
networks:
- gitea
volumes:
- /var/lab/gitea/mysql:/var/lib/mysql
deploy:
placement:
constraints:
- node.id == ${REGISTERid}

1
git.yaml.sh

@ -0,0 +1 @@
env REGISTERid=c50xzv12mz3cux1mcdz4ypznc docker stack deploy -c git.yaml git
Loading…
Cancel
Save