forked from CCCHH/nix-infra
Add deployment_configuration to make deployment using infra-rebuild work
Also document usage of infra-rebuild and its configuration file.
This commit is contained in:
parent
9d7f9d0ec8
commit
46e43e51aa
20
README.md
Normal file
20
README.md
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
# nix-infra
|
||||||
|
|
||||||
|
nix infrastructure configuration for CCCHH.
|
||||||
|
|
||||||
|
For deployment we're using [infra-rebuild](https://git.hamburg.ccc.de/CCCHH/infra-rebuild). \
|
||||||
|
To easily get a shell with `infra-rebuild` going, use the following command:
|
||||||
|
|
||||||
|
```
|
||||||
|
nix shell git+https://git.hamburg.ccc.de/CCCHH/infra-rebuild#infra-rebuild
|
||||||
|
```
|
||||||
|
|
||||||
|
After that you can simply run the following to deploy e.g. the git and matrix hosts:
|
||||||
|
|
||||||
|
```
|
||||||
|
infra-rebuild switch git matrix
|
||||||
|
```
|
||||||
|
|
||||||
|
By default infra-rebuild tries to use the FQDN from the nixosConfiguration of the host for deployment.
|
||||||
|
However to override individual parts of the deployment target, a [`deployment_configuration.json`](./deployment_configuration.json) can be used.
|
||||||
|
This is exactly what we're doing to set the default deployment user to `colmena-deploy` and have custom target hostnames for Chaosknoten hosts, since they don't have an FQDN defined in their nixosConfiguration.
|
28
deployment_configuration.json
Normal file
28
deployment_configuration.json
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
{
|
||||||
|
"default": {
|
||||||
|
"targetUser": "colmena-deploy"
|
||||||
|
},
|
||||||
|
"hosts": {
|
||||||
|
"netbox": {
|
||||||
|
"targetHostname": "netbox-intern.hamburg.ccc.de"
|
||||||
|
},
|
||||||
|
"matrix": {
|
||||||
|
"targetHostname": "matrix-intern.hamburg.ccc.de"
|
||||||
|
},
|
||||||
|
"public-web-static": {
|
||||||
|
"targetHostname": "public-web-static-intern.hamburg.ccc.de"
|
||||||
|
},
|
||||||
|
"git": {
|
||||||
|
"targetHostname": "git.hamburg.ccc.de"
|
||||||
|
},
|
||||||
|
"forgejo-actions-runner": {
|
||||||
|
"targetHostname": "forgejo-actions-runner-intern.hamburg.ccc.de"
|
||||||
|
},
|
||||||
|
"eh22-wiki": {
|
||||||
|
"targetHostname": "eh22-wiki-intern.hamburg.ccc.de"
|
||||||
|
},
|
||||||
|
"nix-box-june": {
|
||||||
|
"targetHostname": "nix-box-june-intern.hamburg.ccc.de"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue