Cleaned repository

- Added explaination to README
- Added docker-compose files
This commit is contained in:
Max W. 2023-12-04 20:56:54 +01:00
parent aba62b3c17
commit 1c082af08a
3 changed files with 68 additions and 2 deletions

View File

@ -1,3 +1,10 @@
# startup
# Sample CI/CD Spring Boot Project
Hallo
This is a sample project to demonstrate CI/CD using Gitea and Gitea Runner.
## Details
Run actions build a executable .jar file with the help of maven. It contains the basic Spring Boot WebApp wich serves a simple HTML page with sample text to `localhost:8080/`.
This project uploads configured artifacts. Checkout `.gitea/workflows` for more details.
The docker compose files used to setup this System can be found in `files` directory.

41
files/docker-compose.yml Normal file
View File

@ -0,0 +1,41 @@
version: "3"
networks:
gitea:
external: false
services:
giteaserver:
image: gitea/gitea:latest
container_name: gitea
environment:
- USER_UID=1000
- USER_GID=1000
- GITEA__database__DB_TYPE=mysql
- GITEA__database__HOST=giteadbdb:3306
- GITEA__database__NAME=gitea
- GITEA__database__USER=gitea
- GITEA__database__PASSWD=gitea
restart: always
networks:
- gitea
volumes:
- ./gitea:/data
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
ports:
- "3000:3000"
- "222:22"
giteadbdb:
image: mysql:8
restart: always
environment:
- MYSQL_ROOT_PASSWORD=gitea
- MYSQL_USER=gitea
- MYSQL_PASSWORD=gitea
- MYSQL_DATABASE=gitea
networks:
- gitea
volumes:
- ./mysql:/var/lib/mysql

18
files/docker-compose2.yml Normal file
View File

@ -0,0 +1,18 @@
version: '3.8'
networks:
gitea:
external: true
services:
gitea_act_runner:
image: gitea/act_runner:nightly
restart: always
networks:
- gitea
volumes:
- /var/run/docker.sock:/var/run/docker.sock:rw
- /opt/gitea_runner_data:/data:rw
environment:
TZ: "Europe/Berlin"
GITEA_INSTANCE_URL: 'https://git.walzen665.de'
GITEA_RUNNER_REGISTRATION_TOKEN: '<YOURTOKENHERE>'