Compare commits
	
		
			20 Commits
		
	
	
		
			1.0.0+1.14
			...
			1.3.0+1.17
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| af97db8082 | |||
| cd39f5fc82 | |||
| aa84c25a83 | |||
| cd3ded3c4e | |||
| 0cad878de5 | |||
| 3a47a4164e | |||
| 8ead189fde | |||
| c8ea311d7d | |||
| b2f29bc99e | |||
| 741b8701e5 | |||
| bb1f0f082e | |||
| cec9c2c061 | |||
| fee8fd5342 | |||
| 83a9e9da6b | |||
| ee34764179 | |||
| d0488d3a61 | |||
| 7009473b38 | |||
| 0547336698 | |||
| 632364fccf | |||
| 1aa71afcf6 | 
@ -1,6 +1,6 @@
 | 
			
		||||
TYPE=gitea
 | 
			
		||||
 | 
			
		||||
DOMAIN=gitea.example.com
 | 
			
		||||
DOMAIN={{ .Domain }}
 | 
			
		||||
LETS_ENCRYPT_ENV=production
 | 
			
		||||
 | 
			
		||||
GITEA_DOMAIN=git.example.com
 | 
			
		||||
@ -11,6 +11,8 @@ GITEA_DISABLE_REGISTRATION=false
 | 
			
		||||
GITEA_ENABLE_NOTIFY_MAIL=true
 | 
			
		||||
GITEA_ENABLE_OPENID_SIGNIN=true
 | 
			
		||||
GITEA_ENABLE_OPENID_SIGNUP=true
 | 
			
		||||
GITEA_DISABLE_GRAVATAR=false
 | 
			
		||||
GITEA_ENABLE_FEDERATED_AVATAR=true
 | 
			
		||||
 | 
			
		||||
GITEA_MAILER_FROM=noreply@example.com
 | 
			
		||||
GITEA_MAILER_USER=noreply@example.com
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										57
									
								
								README.md
									
									
									
									
									
								
							
							
						
						
									
										57
									
								
								README.md
									
									
									
									
									
								
							@ -1,18 +1,16 @@
 | 
			
		||||
# Gitea
 | 
			
		||||
 | 
			
		||||
[](https://drone.coopcloud.tech/coop-cloud/gitea)
 | 
			
		||||
[](https://build.coopcloud.tech/coop-cloud/gitea)
 | 
			
		||||
 | 
			
		||||
<!-- metadata -->
 | 
			
		||||
 | 
			
		||||
- **Category**: Development
 | 
			
		||||
- **Status**: ❷💛
 | 
			
		||||
- **Image**: [`gitea/gitea`](https://hub.docker.com/gitea/gitea), ❶💚, upstream
 | 
			
		||||
- **Healthcheck**: Yes
 | 
			
		||||
- **Backups**: No
 | 
			
		||||
- **Email**: ?
 | 
			
		||||
- **Tests**: ❷💛
 | 
			
		||||
- **SSO**: ❶💚 (OAuth)
 | 
			
		||||
 | 
			
		||||
* **Category**: Development
 | 
			
		||||
* **Status**: 3, stable
 | 
			
		||||
* **Image**: [`gitea/gitea`](https://hub.docker.com/gitea/gitea), 4, upstream
 | 
			
		||||
* **Healthcheck**: Yes
 | 
			
		||||
* **Backups**: Yes
 | 
			
		||||
* **Email**: ?
 | 
			
		||||
* **Tests**: 2
 | 
			
		||||
* **SSO**: 3 (OAuth)
 | 
			
		||||
<!-- endmetadata -->
 | 
			
		||||
 | 
			
		||||
## Basic usage
 | 
			
		||||
@ -24,3 +22,40 @@
 | 
			
		||||
4. `abra app YOURAPPDOMAIN config` - be sure to change `$DOMAIN` to something that resolves to
 | 
			
		||||
   your Docker swarm box
 | 
			
		||||
5. `abra app YOURAPPDOMAIN deploy`
 | 
			
		||||
 | 
			
		||||
## Create first user
 | 
			
		||||
 | 
			
		||||
Run
 | 
			
		||||
 | 
			
		||||
```bash
 | 
			
		||||
abra app run YOURAPPNAME app gitea -c /etc/gitea/app.ini admin user create --username USERNAME --admin --random-password --email EMAIL
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
See the [Gitea command-line documentation](https://docs.gitea.io/en-us/command-line/) for more options.  Make sure not to forget the `-c /etc/gitea/app.ini`.
 | 
			
		||||
 | 
			
		||||
## Enable SSH
 | 
			
		||||
 | 
			
		||||
You most certainly want to be able to access your repository over SSH.  To do so, make sure you uncomment the right lines in the configuration for `traefik`.
 | 
			
		||||
```
 | 
			
		||||
abra app config YOURTRAEFIKAPP
 | 
			
		||||
```
 | 
			
		||||
There uncomment or add these lines:
 | 
			
		||||
```
 | 
			
		||||
GITEA_SSH_ENABLED=1
 | 
			
		||||
COMPOSE_FILE="compose.yml:compose.gitea.yml"
 | 
			
		||||
```
 | 
			
		||||
Then redeploy traefik:
 | 
			
		||||
```
 | 
			
		||||
abra app undeploy YOURTRAEFIKAPP
 | 
			
		||||
abra app deploy YOURTRAEFIKAPP
 | 
			
		||||
```
 | 
			
		||||
You might need to wait a bit.  To check if it worked, you can run
 | 
			
		||||
```
 | 
			
		||||
telnet my.gitea.example.com 2222
 | 
			
		||||
```
 | 
			
		||||
Once you have added a public SSH key, you can check that you can connect to your gitea server with
 | 
			
		||||
```
 | 
			
		||||
ssh -T -p 2222 git@my.gitea.example.com
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
Note that gitea should be configured to listen to port 2222, i.e. `GITEA_SSH_PORT=2222` in the gitea config.
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										14
									
								
								abra.sh
									
									
									
									
									
								
							
							
						
						
									
										14
									
								
								abra.sh
									
									
									
									
									
								
							@ -1,2 +1,14 @@
 | 
			
		||||
export APP_INI_VERSION=v7
 | 
			
		||||
export APP_INI_VERSION=v8
 | 
			
		||||
export DOCKER_SETUP_SH_VERSION=v1
 | 
			
		||||
 | 
			
		||||
abra_backup_app() {
 | 
			
		||||
  _abra_backup_dir "app:/var/lib/gitea"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
abra_backup_db() {
 | 
			
		||||
  _abra_backup_mysql "db" "gitea"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
abra_backup() {
 | 
			
		||||
  abra_backup_app && abra_backup_db
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -7,6 +7,10 @@ NAME = {{ env "GITEA_DB_NAME" }}
 | 
			
		||||
PASSWD = {{ secret "db_password" }}
 | 
			
		||||
USER = {{ env "GITEA_DB_USER" }}
 | 
			
		||||
 | 
			
		||||
[picture]
 | 
			
		||||
DISABLE_GRAVATAR = {{ env "GITEA_DISABLE_GRAVATAR" }}
 | 
			
		||||
ENABLE_FEDERATED_AVATAR = {{ env "GITEA_ENABLE_FEDERATED_AVATAR" }}
 | 
			
		||||
 | 
			
		||||
[service]
 | 
			
		||||
ALLOW_ONLY_EXTERNAL_REGISTRATION = {{ env "GITEA_ALLOW_ONLY_EXTERNAL_REGISTRATION" }}
 | 
			
		||||
AUTO_WATCH_NEW_REPOS = {{ env "GITEA_AUTO_WATCH_NEW_REPOS" }}
 | 
			
		||||
 | 
			
		||||
@ -3,7 +3,7 @@ version: "3.8"
 | 
			
		||||
 | 
			
		||||
services:
 | 
			
		||||
  app:
 | 
			
		||||
    image: "gitea/gitea:1.14.5-rootless"
 | 
			
		||||
    image: "gitea/gitea:1.17.2-rootless"
 | 
			
		||||
    configs:
 | 
			
		||||
      - source: app_ini
 | 
			
		||||
        target: /etc/gitea/app.ini
 | 
			
		||||
@ -30,6 +30,8 @@ services:
 | 
			
		||||
      - GITEA_ENABLE_OPENID_SIGNUP
 | 
			
		||||
      - GITEA_SMTP_MAILER_ENABLED
 | 
			
		||||
      - GITEA_SSH_PORT
 | 
			
		||||
      - GITEA_DISABLE_GRAVATAR
 | 
			
		||||
      - GITEA_ENABLE_FEDERATED_AVATAR
 | 
			
		||||
    volumes:
 | 
			
		||||
      - data:/var/lib/gitea
 | 
			
		||||
      - config:/etc/gitea
 | 
			
		||||
@ -51,7 +53,7 @@ services:
 | 
			
		||||
        - "traefik.tcp.routers.${STACK_NAME}-ssh.rule=HostSNI(`*`)"
 | 
			
		||||
        - "traefik.tcp.routers.${STACK_NAME}-ssh.entrypoints=gitea-ssh"
 | 
			
		||||
        - "traefik.tcp.services.${STACK_NAME}-ssh.loadbalancer.server.port=${GITEA_SSH_PORT}"
 | 
			
		||||
        - coop-cloud.${STACK_NAME}.version=1.0.0+1.14.5-rootless
 | 
			
		||||
        - coop-cloud.${STACK_NAME}.version=1.3.0+1.17.2-rootless
 | 
			
		||||
 | 
			
		||||
  db:
 | 
			
		||||
    image: "mariadb:10.6"
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user