From ddd9a706a928d33a2754c9d621f73f945abe3126 Mon Sep 17 00:00:00 2001 From: JuliusFreudenberger Date: Tue, 29 Mar 2022 19:35:02 +0200 Subject: [PATCH] Add gitea --- gitea/README.md | 4 +++ gitea/docker-compose.yaml | 67 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 71 insertions(+) create mode 100644 gitea/README.md create mode 100644 gitea/docker-compose.yaml diff --git a/gitea/README.md b/gitea/README.md new file mode 100644 index 0000000..7d5313a --- /dev/null +++ b/gitea/README.md @@ -0,0 +1,4 @@ +# gitea + +A community managed lightweight code hosting solution written in Go. + diff --git a/gitea/docker-compose.yaml b/gitea/docker-compose.yaml new file mode 100644 index 0000000..4af9857 --- /dev/null +++ b/gitea/docker-compose.yaml @@ -0,0 +1,67 @@ +version: "3" + +services: + gitea: + image: gitea/gitea:${gitea_version:-latest} + restart: unless-stopped + environment: + - USER_UID=1000 + - USER_GID=1000 + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 + - GITEA__database__NAME=gitea + - GITEA__database__USER=gitea + - GITEA__database__PASSWD=gitea + - GITEA__server__DOMAIN=git.jfreudenberger.de + - GITEA__server__SSH_DOMAIN=git.jfreudenberger.de + - GITEA__server__ROOT_URL=https://git.jfreudenberger.de + - GITEA__server__LFS_JWT_SECRET=${LFS_JWT_SECRET} + - GITEA__security__SECRET_KEY=${SECRET_KEY} + - GITEA__security__INTERNAL_TOKEN=${INTERNAL_TOKEN} + - GITEA__service__NO_REPLY_ADDRESS=${NO_REPLY_ADDRESS:-noreply@jfreudenberger.de} + - GITEA__oauth__JWT_SECRET=${OAUTH_JWT_SECRET} + - GITEA__mailer__ENABLED=${MAILER_ENABLED:-false} + - GITEA__mailer__HOST=${MAILER_HOST} + - GITEA__mailer__FROM=${MAILER_FROM} + - GITEA__mailer__USER=${MAILER_USER} + - GITEA__mailer__PASSWD=${MAILER_PASSWD} + - VIRTUAL_HOST=git.jfreudenberger.de + - VIRTUAL_PORT=3000 + - LETSENCRYPT_HOST=git.jfreudenberger.de + volumes: + - gitea-data:/data + - gitea-backup:/backup + - /etc/timezone:/etc/timezone:ro + - /etc/localtime:/etc/localtime:ro + ports: + - "222:22" + depends_on: + - db + networks: + - gitea + - webproxy + + db: + image: mariadb:${mariadb_version:-10.7} + restart: unless-stopped + environment: + - MARIADB_ROOT_PASSWORD=gitea + - MARIADB_USER=gitea + - MARIADB_PASSWORD=gitea + - MARIADB_DATABASE=gitea + volumes: + - mariadb-data:/var/lib/mysql + networks: + - gitea + +volumes: + gitea-data: + gitea-backup: + mariadb-data: + +networks: + gitea: + webproxy: + external: true + name: webproxy +