c4k-jitsi/doc/SetupOnHetzner.md

72 lines
1.3 KiB
Markdown
Raw Normal View History

2022-02-09 10:48:24 +01:00
# Setup
## Infrastructure on Hetzner / Aws
For a setup on hetzner / aws we use terraform.
```
resource "aws_s3_bucket" "backup" {
bucket = "backup"
acl = "private"
versioning {
enabled = false
}
tags = {
name = "backup"
Description = "bucket for backups in stage: ${var.stage}"
}
}
2025-02-21 11:49:54 +01:00
resource "hcloud_server" "jitsi_2025_02" {
2022-02-09 10:48:24 +01:00
name = "the name"
2025-02-21 11:49:54 +01:00
image = "ubuntu-24.04"
server_type = "cx32"
2022-02-09 10:48:24 +01:00
location = "fsn1"
ssh_keys = ...
lifecycle {
ignore_changes = [ssh_keys]
}
}
2025-02-21 11:49:54 +01:00
resource "aws_route53_record" "v4" {
for_each ["jitsi", "stun.jitsi", "excalidraw.jitsi", "etherpad.jitsi"]
2022-02-09 10:48:24 +01:00
zone_id = the_dns_zone
2025-02-21 11:49:54 +01:00
name = each.key
2022-02-09 10:48:24 +01:00
type = "A"
ttl = "300"
2025-02-21 11:49:54 +01:00
records = [hcloud_server.jitsi_2025_01.ipv4_address]
2022-02-09 10:48:24 +01:00
}
output "ipv4" {
2025-02-21 11:49:54 +01:00
value = hcloud_server.jitsi_2025_01.ipv4_address
2022-02-09 10:48:24 +01:00
}
```
## k8s minicluster
2025-02-26 18:35:05 +01:00
For k8s installation we use our [provs](https://repo.prod.meissa.de/meissa/provs) with the following configuration:
2022-02-09 10:48:24 +01:00
```
2025-02-21 11:49:54 +01:00
{:fqdn "fqdn-from-above"
:node {:ipv4 "ip-from-above"}
2025-02-26 18:35:05 +01:00
:certmanager {:email "admin-email" :letsencryptEndpoint "prod"}}
2022-02-09 10:48:24 +01:00
```
2022-02-09 10:49:45 +01:00
## kubectl apply c4k-jitsi
2022-02-09 10:48:24 +01:00
2022-02-09 10:49:45 +01:00
The last step for applying the jitsi deployment is
2022-02-09 10:48:24 +01:00
```
2022-02-09 10:49:45 +01:00
c4k-jitsi config.edn auth.edn | kubectl apply -f -
2022-02-09 10:48:24 +01:00
```
with the following config.edn:
```
2025-02-21 11:49:54 +01:00
{:fqdn "fqdn-from-above"
2022-12-27 08:50:48 +01:00
:issuer "prod" }
2022-02-09 10:48:24 +01:00
```