基于docker搭建gitea,数据库直接使用阿里云的RDS,需要修改docker-compose.yml文件,增加dns设置
version: "3"
networks:
gitea:
external: false
services:
server:
dns:
- 100.100.2.136
- 100.100.2.138
image: gitea/gitea:1.21.1
container_name: gitea
restart: always
networks:
- gitea
volumes:
- /home/dev/docker/gitea:/data
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
ports:
- "3000:3000"
- "3022:22"
environment:
- DISABLE_REGISTRATION=true
- SHOW_REGISTRATION_BUTTON=false
- ALLOW_ONLY_INTERNAL_REGISTRATION=true
网友评论