No description
- Go 78.9%
- Shell 21.1%
chore(deps): update go toolchain directive to v1.26.5 See merge request sheogorath/hcloud-dynfw!301 |
||
|---|---|---|
| systemd | ||
| vendor | ||
| .gitignore | ||
| .gitlab-ci.yml | ||
| .ko.yaml | ||
| .semrelrc | ||
| go.mod | ||
| go.sum | ||
| LICENSE | ||
| main.go | ||
| README.md | ||
| renovate.json | ||
Hetzner.Cloud Dynmaic Firewall
Disclaimer
Be aware that this is neither any official project nor suited for professional use. It's mainly a toy project playing around with Golang and the hetzner API client.
Don't cry when something breaks or eats your cat.
Build & Install
go build .
# Fetch the API token from hetzner and store it with the following command:
secret-tool store --label "hetzner-dynamic-firewall API key" com.shivering-isles.git.sheogorath.hcloud-dynfw/api.hetzner.cloud api-key
# Store the firewall ID in the from the URL: https://console.hetzner.cloud/projects/(project ID)/firewalls/<FIREWALL ID>/rules
mkdir -p ~/.config/hcloud-dynfw/
echo "HCLOUD_FIREWALL_ID=<FIREWALL ID>" > ~/.config/hcloud-dynfw/env
Build the container
The container build uses ko:
ko build .