From 9fcea5424c25562fc71fa2f0250dac254ba3a89f Mon Sep 17 00:00:00 2001 From: Franck Cuny Date: Wed, 11 May 2022 12:15:24 -0700 Subject: add a script to deploy the site Instead of using the Makefile, move the content to a script. This will be executed by drone later. --- users/fcuny/notes/scripts/deploy.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100755 users/fcuny/notes/scripts/deploy.sh (limited to 'users/fcuny/notes/scripts') diff --git a/users/fcuny/notes/scripts/deploy.sh b/users/fcuny/notes/scripts/deploy.sh new file mode 100755 index 0000000..4075f08 --- /dev/null +++ b/users/fcuny/notes/scripts/deploy.sh @@ -0,0 +1,14 @@ +#!/usr/bin/env bash + +git diff --exit-code +git diff --staged --exit-code + +flyctl deploy + +VERSION=$(flyctl info -j |jq -r '.App | "notes.fcuny.net/v\(.Version)"') + +git tag -a --message ${VERSION} ${VERSION} +git push origin --all +git push origin --tags + +flyctl agent stop -- cgit 1.4.1