~evanj/cms

ccbab982a48f7233694fafaebbd7e7d456e9e54e — Evan M Jones 5 months ago 27de4d9
Feat(.build.yml): Automated deploys via https://builds.sr.ht/
1 files changed, 23 insertions(+), 0 deletions(-)

A .build.yml
A .build.yml => .build.yml +23 -0
@@ 0,0 1,23 @@
image: ubuntu/latest
arch: amd64
packages:
  - make
sources:
  - https://git.sr.ht/~evanj/cms
secrets:
  - 0154a9d3-f2c9-4ee2-8102-7c4c92492149
tasks:
  - build: |
      # go setup.
      wget https://dl.google.com/go/go1.14.4.linux-amd64.tar.gz
      sudo tar -C /usr/local -xzf go1.14.4.linux-amd64.tar.gz
      mkdir -p "$HOME/go/bin"
      export PATH="$PATH:$PATH:/usr/local/go/bin:$HOME/go/bin"
      # cms build.
      cd cms
      touch .env
      make gen
      make build
      ssh -o 'StrictHostKeyChecking=no' evan@140.82.14.80 'bash -c "rm ~/cms/cms 2>/dev/null"'
      scp -o 'StrictHostKeyChecking=no' cms evan@140.82.14.80:~/cms
      ssh -o 'StrictHostKeyChecking=no' evan@140.82.14.80 'bash -c "sudo systemctl restart cms"'