Skip to content

Hide address form if chain is not published #122

Hide address form if chain is not published

Hide address form if chain is not published #122

name: Deploy Acceptance Server
on:
workflow_dispatch:
push:
branches:
- main
paths:
- server/**
jobs:
deploy-api:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: "1.20"
check-latest: true
cache: true
cache-dependency-path: server/go.sum
- name: Build binary
run: make build-server
working-directory: ./server
- name: Rename binary
run: mv server cl-api-acceptance
working-directory: ./server
- name: Install SSH key
uses: benoitchantre/[email protected]
with:
private-key: ${{ secrets.VPS1_PRIVKEY }}
known-hosts: ${{ secrets.VPS1_KNOWNHOSTS }}
- name: Send binary to vps and restart service
run: |
rsync -az --delete ./server/cl-api-acceptance [email protected]:/home/admin/
ssh [email protected] "\
sudo rm /home/clothingloop/opt/api-acceptance; \
sudo cp /home/admin/cl-api-acceptance /home/clothingloop/opt/api-acceptance; \
sudo chown root:root /home/clothingloop/opt/api-acceptance; \
sudo chmod 0775 /home/clothingloop/opt/api-acceptance; \
sudo systemctl restart cl-api-acceptance"
echo "done"