Deploy #357
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy | |
on: | |
workflow_dispatch: | |
env: | |
WORKING_DIRECTORY: BlazorSchoolDocs | |
VPS_WEB_DIRECTORY: /home/blazorschool3/client/wwwroot | |
jobs: | |
build-and-deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@master | |
- name: Copy web via ssh | |
uses: garygrossgarten/github-action-scp@master | |
with: | |
local: contents | |
remote: ${{ env.VPS_WEB_DIRECTORY }} | |
host: ${{ secrets.HOST }} | |
username: ${{ secrets.USERNAME }} | |
password: ${{ secrets.PASSWORD }} | |
- name: Restart BlazorSchool Server service | |
uses: garygrossgarten/github-action-ssh@master | |
with: | |
host: ${{ secrets.HOST }} | |
command: | | |
systemctl daemon-reload | |
systemctl restart BlazorSchool3Server | |
username: ${{ secrets.USERNAME }} | |
password: ${{ secrets.PASSWORD }} |