Sign in

Search issue titles and bodies, change requests and comments. Private repositories you cannot read are not included.

vole
Clone

Read only, no credentials:

https://rodent.software/vole.git

Write over SSH with a registered key:

git clone ssh://git@rodent.software:2222/vole.git

A free and open-source forge that lives in your Git repo.

Drop the Terraform configurations; cloud-init is the deployment path

51624dc663738e70cc37b8ac5e232841fd49aaf8 · Keenan Nemetz · 3d ago · parent e21f6c5e

Drop the Terraform configurations; cloud-init is the deployment path

A Vole instance is one package, one configuration file, and one directory.
The first-boot file that installs the package and writes the configuration
is that same work described once, and it needs no provider, no state file,
and no cloud token with write access to an account. What Terraform did
outside the machine — firewall, address, DNS record — is three fields in a
console the operator already has open.

So the three configurations go, and with them what existed only to check
them: the pinned Terraform download in the verify image, the `fmt -check`
step, the .terraform entries in the ignore file, and the directory skip in
the link checker. The deployment check now needs python3 and PyYAML and
nothing else — no network, no credentials.

deploy/README.md keeps the reasoning, so the next person tempted to add a
provider back sees what it would buy and what it would cost.

The templates' header comments no longer name a renderer that is gone:
render.sh fills them in, and check-deploy.py renders them the same way.

deploy/terraform/digitalocean/outputs.tf −43

@@ -1,43 +0,0 @@
1 output "web_url" {
2 description = "Where the instance answers, and what public_url is set to."
3 value = "https://${var.domain}"
4 }
5
6 output "git_remote" {
7 description = "SSH address to clone from once a repository exists."
8 value = "ssh://git@${var.domain}:2222/"
9 }
10
11 output "public_ipv4" {
12 description = "Point your own DNS at this if create_dns is false."
13 value = digitalocean_droplet.vole.ipv4_address
14 }
15
16 output "admin_account" {
17 description = "The instance admin created at first boot. Sign in with the key you passed in."
18 value = var.admin_account
19 }
20
21 output "server_login" {
22 description = "Shell access to the machine, for repairs and backups. Vole's own Git SSH is on 2222."
23 value = "ssh root@${digitalocean_droplet.vole.ipv4_address}"
24 }
25
26 output "dns_record" {
27 description = "The record created when create_dns is true."
28 value = var.create_dns ? "${var.domain} A ${digitalocean_droplet.vole.ipv4_address}" : "not managed here; point ${var.domain} at ${digitalocean_droplet.vole.ipv4_address}"
29 }
30
31 output "runner_ipv4" {
32 description = "The runner's address, or null when runner is false. Its only use is a shell."
33 value = var.runner ? digitalocean_droplet.runner[0].ipv4_address : null
34 }
35
36 output "runner_setup" {
37 description = "The commands that let the runner take jobs. Run them from a machine that holds your admin key."
38 value = var.runner ? join("\n", [
39 "ssh root@${digitalocean_droplet.runner[0].ipv4_address} cat /var/lib/vole-runner/.ssh/id_ed25519.pub | vole admin --remote ssh://git@${var.domain}:2222 account create ci-runner-1 --bot --key -",
40 "vole admin --remote ssh://git@${var.domain}:2222 acl runners add <repo> ci-runner-1",
41 "vole admin --remote ssh://git@${var.domain}:2222 acl set-role <repo> ci-runner-1 read",
42 ]) : "runner is false: pass -var runner=true to create one"
43 }