mirror of
https://github.com/davegallant/davegallant.github.io.git
synced 2026-01-04 17:42:30 +00:00
Compare commits
4 Commits
d3e0336375
...
renovate/t
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a73c31eac9 | ||
| 47e1792caa | |||
| d4b0e599db | |||
| f433fb9f1c |
@@ -18,7 +18,6 @@ If you would like to connect with me:
|
||||
- [Mastodon](https://mastodon.social/@davegallant)
|
||||
- [GitHub](https://github.com/davegallant)
|
||||
- [RSS Feed](https://davegallant.ca/index.xml)
|
||||
- [gitea.snake-cloud.ts.net](https://gitea.snake-cloud.ts.net/explore/repos)
|
||||
|
||||
## Credits
|
||||
|
||||
|
||||
@@ -50,11 +50,9 @@ services:
|
||||
gitea:
|
||||
image: gitea/gitea:1.21.1
|
||||
container_name: gitea
|
||||
network_mode: service:ts-gitea
|
||||
environment:
|
||||
- USER_UID=1000
|
||||
- USER_GID=1000
|
||||
|
||||
- GITEA__server__DOMAIN=gitea.my-tailnet-name.ts.net
|
||||
- GITEA__server__ROOT_URL=https://gitea.my-tailnet-name.ts.net
|
||||
- GITEA__server__HTTP_ADDR=0.0.0.0
|
||||
@@ -64,57 +62,18 @@ services:
|
||||
- ./data:/data
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ts-gitea:
|
||||
image: tailscale/tailscale:v1.58
|
||||
container_name: ts-gitea
|
||||
hostname: gitea
|
||||
environment:
|
||||
- TS_AUTHKEY=<FILL THIS IN>
|
||||
- TS_SERVE_CONFIG=/config/gitea.json
|
||||
- TS_STATE_DIR=/var/lib/tailscale
|
||||
volumes:
|
||||
- ${PWD}/state:/var/lib/tailscale
|
||||
- ${PWD}/config:/config
|
||||
- /dev/net/tun:/dev/net/tun
|
||||
cap_add:
|
||||
- net_admin
|
||||
- sys_module
|
||||
restart: unless-stopped
|
||||
```
|
||||
|
||||
Note that you must specify a `TS_AUTHKEY` in the `ts-gitea` service. You can generate an auth key [here](https://login.tailscale.com/admin/settings/keys).
|
||||
After adding the above configuration, running `docker compose up -d` should be enough to get an instance up and running.
|
||||
|
||||
`config/gitea.json`:
|
||||
To make it accessible at [https://gitea.my-tailnet-name.ts.net](https://gitea.my-tailnet-name.ts.net) from within the tailnet, install tailscale cli and run:
|
||||
|
||||
```yaml
|
||||
{
|
||||
"TCP": { "443": { "HTTPS": true } },
|
||||
"Web":
|
||||
{
|
||||
"${TS_CERT_DOMAIN}:443":
|
||||
{ "Handlers": { "/": { "Proxy": "http://127.0.0.1:3000" } } },
|
||||
},
|
||||
"AllowFunnel": { "${TS_CERT_DOMAIN}:443": false }
|
||||
}
|
||||
```sh
|
||||
tailscale serve -bg 3000
|
||||
```
|
||||
|
||||
After adding the above configuration, running `docker compose up -d` should be enough to get an instance up and running. It will be accessible at [https://gitea.my-tailnet-name.ts.net](https://gitea.my-tailnet-name.ts.net) from within the tailnet.
|
||||
|
||||
Something to consider is whether or not you want to use ssh with git. One method to get this to work with containers is to use [ssh container passthrough](https://docs.gitea.com/installation/install-with-docker#ssh-container-passthrough). I decided to keep it simple and not use ssh, since communicating over https is perfectly fine for my use case.
|
||||
|
||||
## Theming
|
||||
|
||||
I discovered some themes for gitea [here](https://git.sainnhe.dev/sainnhe/gitea-themes).
|
||||
|
||||
I added the theme by copying [theme-palenight.css](https://git.sainnhe.dev/sainnhe/gitea-themes/raw/branch/master/dist/theme-palenight.css) into `./data/gitea/public/assets/css`. I then added the following to `environment` in `docker-compose.yml`:
|
||||
|
||||
```yaml
|
||||
- GITEA__ui__DEFAULT_THEME=palenight
|
||||
- GITEA__ui__THEMES=palenight
|
||||
```
|
||||
|
||||
After restarting the gitea instance, the default theme was applied.
|
||||
|
||||
## Connecting runners
|
||||
|
||||
I installed the runner by [following the docs](https://docs.gitea.com/usage/actions/quickstart#set-up-runner). I opted for installing it on a separate host as recommended in the docs. I used the systemd unit file to ensure that the runner comes back online after system reboots. I installed tailscale on the gitea runner as well, so that it can be part of the same tailnet as the main instance.
|
||||
@@ -168,7 +127,7 @@ jobs:
|
||||
${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_number }}
|
||||
```
|
||||
|
||||
And voilà:
|
||||
And the end result:
|
||||
|
||||

|
||||
|
||||
@@ -182,6 +141,4 @@ One enhancement that I would like to see is the ability to send notifications on
|
||||
|
||||
Gitea Actions are fast and the resource footprint is minimal. My gitea instance is currently using around 250mb of memory and a small fraction of a single cpu core (and the runner is using a similar amount of resources). This is impressive since many alternatives tend to require substantially more resources. It likely helps that the codebase is largely written in go.
|
||||
|
||||
By combining gitea with the networking marvel that is tailscale, running workflows becomes simple and fun. Whether you are working on a team or working alone, this setup ensures that your workflows are securely accessible from anywhere with an internet connection.
|
||||
|
||||
Check out my gitea instance exposed via Funnel [here](https://gitea.snake-cloud.ts.net).
|
||||
By combining gitea with tailscale, running workflows becomes simple and fun. Whether you are working on a team or working alone, this setup ensures that your workflows are securely accessible from anywhere with an internet connection.
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
<!-- Umami Analytics -->
|
||||
<script defer src="https://umami.snake-cloud.ts.net/script.js" data-website-id="e8adafba-b892-4dad-a139-2bd61fe5fab9"></script>
|
||||
<script defer src="https://umami.davegallant.ca/script.js" data-website-id="e8adafba-b892-4dad-a139-2bd61fe5fab9"></script>
|
||||
|
||||
16
package-lock.json
generated
16
package-lock.json
generated
@@ -335,6 +335,7 @@
|
||||
}
|
||||
],
|
||||
"license": "MIT",
|
||||
"peer": true,
|
||||
"engines": {
|
||||
"node": "^14 || ^16 || >=18"
|
||||
},
|
||||
@@ -358,6 +359,7 @@
|
||||
}
|
||||
],
|
||||
"license": "MIT",
|
||||
"peer": true,
|
||||
"engines": {
|
||||
"node": "^14 || ^16 || >=18"
|
||||
}
|
||||
@@ -1394,9 +1396,10 @@
|
||||
}
|
||||
},
|
||||
"node_modules/@tabler/icons": {
|
||||
"version": "2.45.0",
|
||||
"resolved": "https://registry.npmjs.org/@tabler/icons/-/icons-2.45.0.tgz",
|
||||
"integrity": "sha512-J10UDghOni9wlrj5CpKAzychDCABCKYq897mGg0wGFsd+tYLaUdz0dt/HZeGnV8gZJo0hIiTPLGwBp5EW42Qsg==",
|
||||
"version": "2.47.0",
|
||||
"resolved": "https://registry.npmjs.org/@tabler/icons/-/icons-2.47.0.tgz",
|
||||
"integrity": "sha512-4w5evLh+7FUUiA1GucvGj2ReX2TvOjEr4ejXdwL/bsjoSkof6r1gQmzqI+VHrE2CpJpB3al7bCTulOkFa/RcyA==",
|
||||
"license": "MIT",
|
||||
"funding": {
|
||||
"type": "github",
|
||||
"url": "https://github.com/sponsors/codecalm"
|
||||
@@ -1422,6 +1425,7 @@
|
||||
"resolved": "https://registry.npmjs.org/acorn/-/acorn-8.11.3.tgz",
|
||||
"integrity": "sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==",
|
||||
"dev": true,
|
||||
"peer": true,
|
||||
"bin": {
|
||||
"acorn": "bin/acorn"
|
||||
},
|
||||
@@ -1641,6 +1645,7 @@
|
||||
"url": "https://github.com/sponsors/ai"
|
||||
}
|
||||
],
|
||||
"peer": true,
|
||||
"dependencies": {
|
||||
"caniuse-lite": "^1.0.30001565",
|
||||
"electron-to-chromium": "^1.4.601",
|
||||
@@ -2411,6 +2416,7 @@
|
||||
"resolved": "https://registry.npmjs.org/eslint/-/eslint-8.56.0.tgz",
|
||||
"integrity": "sha512-Go19xM6T9puCOWntie1/P997aXxFsOi37JIHRWI514Hc6ZnaHGKY9xFhrU65RT6CcBEzZoGG1e6Nq+DT04ZtZQ==",
|
||||
"dev": true,
|
||||
"peer": true,
|
||||
"dependencies": {
|
||||
"@eslint-community/eslint-utils": "^4.2.0",
|
||||
"@eslint-community/regexpp": "^4.6.1",
|
||||
@@ -2466,6 +2472,7 @@
|
||||
"resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-9.1.0.tgz",
|
||||
"integrity": "sha512-NSWl5BFQWEPi1j4TjVNItzYV7dZXZ+wP6I6ZhrBGpChQhZRUaElihE9uRRkcbRnNb76UMKDF3r+WTmNcGPKsqw==",
|
||||
"dev": true,
|
||||
"peer": true,
|
||||
"bin": {
|
||||
"eslint-config-prettier": "bin/cli.js"
|
||||
},
|
||||
@@ -4131,6 +4138,7 @@
|
||||
}
|
||||
],
|
||||
"license": "MIT",
|
||||
"peer": true,
|
||||
"dependencies": {
|
||||
"nanoid": "^3.3.8",
|
||||
"picocolors": "^1.1.1",
|
||||
@@ -5305,6 +5313,7 @@
|
||||
"resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.0.15.tgz",
|
||||
"integrity": "sha512-rEYkQOMUCEMhsKbK66tbEU9QVIxbhN18YiniAwA7XQYTVBqrBy+P2p5JcdqsHgKM2zWylp8d7J6eszocfds5Sw==",
|
||||
"dev": true,
|
||||
"peer": true,
|
||||
"dependencies": {
|
||||
"cssesc": "^3.0.0",
|
||||
"util-deprecate": "^1.0.2"
|
||||
@@ -5394,6 +5403,7 @@
|
||||
"resolved": "https://registry.npmjs.org/prettier/-/prettier-3.1.1.tgz",
|
||||
"integrity": "sha512-22UbSzg8luF4UuZtzgiUOfcGM8s4tjBv6dJRT7j275NXsy2jb4aJa4NNveul5x4eqlF1wuhuR2RElK71RvmVaw==",
|
||||
"dev": true,
|
||||
"peer": true,
|
||||
"bin": {
|
||||
"prettier": "bin/prettier.cjs"
|
||||
},
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
let
|
||||
nixpkgs = fetchTarball "https://github.com/NixOS/nixpkgs/tarball/nixos-24.11";
|
||||
nixpkgs = fetchTarball "https://github.com/NixOS/nixpkgs/tarball/nixos-25.11";
|
||||
pkgs = import nixpkgs { config = { }; overlays = [ ]; };
|
||||
in
|
||||
|
||||
|
||||
12
themes/custom-theme/package-lock.json
generated
12
themes/custom-theme/package-lock.json
generated
@@ -1368,9 +1368,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/@tabler/icons": {
|
||||
"version": "2.44.0",
|
||||
"resolved": "https://registry.npmjs.org/@tabler/icons/-/icons-2.44.0.tgz",
|
||||
"integrity": "sha512-WPPtihDcAwEm1QZM9MXQw6+r/R2/qx7KMU1eegsi9DsqBLAb0W2kbt6e/syvd6j9c+6XNpRVBW1ziGqSWQAWOg==",
|
||||
"version": "2.47.0",
|
||||
"resolved": "https://registry.npmjs.org/@tabler/icons/-/icons-2.47.0.tgz",
|
||||
"integrity": "sha512-4w5evLh+7FUUiA1GucvGj2ReX2TvOjEr4ejXdwL/bsjoSkof6r1gQmzqI+VHrE2CpJpB3al7bCTulOkFa/RcyA==",
|
||||
"funding": {
|
||||
"type": "github",
|
||||
"url": "https://github.com/sponsors/codecalm"
|
||||
@@ -7569,9 +7569,9 @@
|
||||
"dev": true
|
||||
},
|
||||
"@tabler/icons": {
|
||||
"version": "2.44.0",
|
||||
"resolved": "https://registry.npmjs.org/@tabler/icons/-/icons-2.44.0.tgz",
|
||||
"integrity": "sha512-WPPtihDcAwEm1QZM9MXQw6+r/R2/qx7KMU1eegsi9DsqBLAb0W2kbt6e/syvd6j9c+6XNpRVBW1ziGqSWQAWOg=="
|
||||
"version": "2.47.0",
|
||||
"resolved": "https://registry.npmjs.org/@tabler/icons/-/icons-2.47.0.tgz",
|
||||
"integrity": "sha512-4w5evLh+7FUUiA1GucvGj2ReX2TvOjEr4ejXdwL/bsjoSkof6r1gQmzqI+VHrE2CpJpB3al7bCTulOkFa/RcyA=="
|
||||
},
|
||||
"@trysound/sax": {
|
||||
"version": "0.2.0",
|
||||
|
||||
Reference in New Issue
Block a user