servnest-containers/setup-xoq.sh

14 lines
1,018 B
Bash
Raw Normal View History

2025-01-22 19:13:59 +01:00
#!/usr/bin/env sh
2024-12-19 15:50:52 +01:00
ENGINE="podman" # "podman" or "docker"
2024-12-19 15:50:52 +01:00
2025-01-22 19:14:30 +01:00
$ENGINE-compose --profile=secondary exec knot-secondary knotc conf-begin
$ENGINE-compose --profile=secondary exec knot-secondary knotc conf-unset remote[primary].cert-key
$ENGINE-compose --profile=secondary exec knot-secondary knotc conf-set remote[primary].cert-key "$($ENGINE-compose --profile=secondary exec knot cat /var/log/knot/knot.log | grep "certificate public key" | cut -d " " -f 7 | tail -1 | tr -d "\r")"
$ENGINE-compose --profile=secondary exec knot-secondary knotc conf-commit
2024-12-19 15:50:52 +01:00
2025-01-22 19:14:30 +01:00
$ENGINE-compose --profile=secondary exec knot knotc conf-begin
$ENGINE-compose --profile=secondary exec knot knotc conf-unset remote[secondary].cert-key
$ENGINE-compose --profile=secondary exec knot knotc conf-set remote[secondary].cert-key "$($ENGINE-compose --profile=secondary exec knot-secondary cat /var/log/knot/knot.log | grep "certificate public key" | cut -d " " -f 7 | tail -1 | tr -d "\r")"
$ENGINE-compose --profile=secondary exec knot knotc conf-commit