mirror of
https://github.com/cunnie/sslip.io.git
synced 2025-10-08 00:51:04 +08:00
Release Procedure: Include GCP
Previously the GCP NS was a k8s container, but now it's a standalone VM (for, believe it or not, cost reasons: it was cheaper to assign a static IP to a VM than to a load balancer). The instructions now include the procedure to update the GCP VM. Also, we double-checked that all servers had the same version number twice, and now we only do it once. And we incorporate it with another step, so there are two fewer steps to follow.
This commit is contained in:
@@ -17,7 +17,9 @@ sed -i '' "s~/$OLD_VERSION/~/$VERSION/~g" \
|
||||
k8s/document_root_sslip.io/index.html \
|
||||
k8s/Dockerfile-sslip.io-dns-server
|
||||
```
|
||||
|
||||
Optional: Update the version for the ns-aws, ns-azure install scripts
|
||||
|
||||
```bash
|
||||
pushd ~/bin
|
||||
sed -i '' "s~/$OLD_VERSION/~/$VERSION/~g" \
|
||||
@@ -27,13 +29,17 @@ git ci -m"Update sslip.io DNS server $OLD_VERSION → $VERSION"
|
||||
git push
|
||||
popd
|
||||
```
|
||||
|
||||
Build & start the new executables:
|
||||
|
||||
```bash
|
||||
bin/make_all
|
||||
# Start the server, assuming macOS M1. Adjust path for GOOS, GOARCH. Linux requires `sudo`
|
||||
bin/sslip.io-dns-server-darwin-arm64
|
||||
```
|
||||
|
||||
Test from another window:
|
||||
|
||||
```bash
|
||||
export DNS_SERVER_IP=127.0.0.1
|
||||
export VERSION=3.1.0
|
||||
@@ -66,41 +72,47 @@ echo "127-0-0-1.sslip.io."
|
||||
dig @$DNS_SERVER_IP metrics.status.sslip.io txt +short | grep '"Queries: '
|
||||
echo '"Queries: 12 (?.?/s)"'
|
||||
```
|
||||
|
||||
Review the output then close the second window. Stop the server in the
|
||||
original window. Commit our changes:
|
||||
|
||||
```bash
|
||||
git add -p
|
||||
# and commit (but DON'T push)
|
||||
git ci -vm"$VERSION: Shorten TTL for publicly-accessible A & AAAA records"
|
||||
git tag $VERSION
|
||||
git push
|
||||
git push --tags
|
||||
scp bin/sslip.io-dns-server-linux-arm64 ns-aws:
|
||||
scp bin/sslip.io-dns-server-linux-amd64 ns-azure:
|
||||
scp bin/sslip.io-dns-server-linux-amd64 ns-gce:
|
||||
ssh ns-aws sudo install sslip.io-dns-server-linux-arm64 /usr/bin/sslip.io-dns-server
|
||||
ssh ns-aws sudo shutdown -r now
|
||||
sleep 10; while ! dig @ns-aws.sslip.io ns-aws.sslip.io; do sleep 5; done # wait until it's back up before rebooting ns-azure
|
||||
# check version number:
|
||||
sleep 10; while ! dig txt @ns-aws.sslip.io version.status.sslip.io +short; do sleep 5; done # wait until it's back up before rebooting ns-azure
|
||||
ssh ns-azure sudo install sslip.io-dns-server-linux-amd64 /usr/bin/sslip.io-dns-server
|
||||
ssh ns-azure sudo shutdown -r now
|
||||
sleep 10; while ! dig @ns-azure.sslip.io ns-azure.sslip.io; do sleep 5; done # wait until it's back up before rebooting ns-azure
|
||||
dig @ns-aws.sslip.io version.status.sslip.io txt +short # confirm new version
|
||||
dig @ns-azure.sslip.io version.status.sslip.io txt +short # confirm new version
|
||||
# check version number:
|
||||
sleep 10; while ! dig txt @ns-azure.sslip.io version.status.sslip.io +short; do sleep 5; done # wait until it's back up before rebooting ns-azure
|
||||
ssh ns-gce sudo install sslip.io-dns-server-linux-amd64 /usr/bin/sslip.io-dns-server
|
||||
ssh ns-gce sudo shutdown -r now
|
||||
# check version number:
|
||||
sleep 10; while ! dig txt @ns-gce.sslip.io version.status.sslip.io +short; do sleep 5; done # wait until it's back up before rebooting ns-gce
|
||||
```
|
||||
|
||||
- Browse to <https://github.com/cunnie/sslip.io/releases/new> to draft a new release
|
||||
- Drag and drop the executables in `bin/` to the _Attach binaries..._ section.
|
||||
- Click "Publish release"
|
||||
|
||||
```bash
|
||||
fly -t nono trigger-job -j sslip.io/build-and-push-sslip.io-dns-server
|
||||
```
|
||||
|
||||
Update the webservers with the HTML with new versions:
|
||||
|
||||
```bash
|
||||
ssh nono.io curl -L -o /www/sslip.io/document_root/index.html https://raw.githubusercontent.com/cunnie/sslip.io/main/k8s/document_root_sslip.io/index.html
|
||||
ssh ns-aws.sslip.io curl -L -o /var/nginx/sslip.io/index.html https://raw.githubusercontent.com/cunnie/sslip.io/main/k8s/document_root_sslip.io/index.html
|
||||
ssh ns-azure.sslip.io curl -L -o /var/nginx/sslip.io/index.html https://raw.githubusercontent.com/cunnie/sslip.io/main/k8s/document_root_sslip.io/index.html
|
||||
```
|
||||
Check that the versions of the sslip.io DNS servers are the same:
|
||||
```bash
|
||||
for IAAS in aws azure gce; do printf "\n$IAAS:\n"; dig @ns-$IAAS.sslip.io version.status.sslip.io txt +short; done
|
||||
fly -t nono trigger-job -j sslip.io/dns-servers
|
||||
```
|
||||
Browse to <https://ci.nono.io/teams/main/pipelines/sslip.io>
|
||||
|
||||
Browse to <https://ci.nono.io/teams/main/pipelines/sslip.io> and check that everything is green.
|
||||
|
Reference in New Issue
Block a user