File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change 5757 subject-name : ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
5858 subject-digest : ${{ steps.push.outputs.digest }}
5959 push-to-registry : true
60+
61+ - name : Restart service
62+ run : |
63+ wget https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-amd64 -O /usr/local/bin/cloudflared &&
64+ chmod +x /usr/local/bin/cloudflared &&
65+ mkdir ~/.ssh/ &&
66+ echo "${{ secrets.GIT_PRIVATE_KEY }}" > ~/.ssh/id_ed25519 &&
67+ chmod 600 ~/.ssh/id_ed25519 &&
68+ ssh -o "StrictHostKeyChecking no" -o ProxyCommand="/usr/local/bin/cloudflared access ssh --hostname %h" -i ~/.ssh/id_ed25519 ${{ secrets.GIT_USERNAME }}@${{ secrets.GIT_REMOTE_HOST }} sudo systemctl restart ${{ secrets.GIT_REMOTE_SERVICE }}
You can’t perform that action at this time.
0 commit comments