replace eg with tomavant3 #60
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: CI | |
| on: | |
| push: | |
| branches: | |
| - '**' | |
| jobs: | |
| build: | |
| name: Build & Test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '10.0.x' | |
| - name: Restore | |
| run: dotnet restore ./Studue/Studue.csproj | |
| - name: Build | |
| run: dotnet publish ./Studue/Studue.csproj --configuration Release --no-restore --output ./ReleaseBuild | |
| - name: CopyToServer | |
| uses: appleboy/scp-action@v1 | |
| with: | |
| host: studue.ch | |
| key: ${{ secrets.DEPLOY_SSH_PRIVATE_KEY }} | |
| username: studue | |
| password: ${{ secrets.DEPLOY_SSH_PASSWORD }} | |
| source: "./ReleaseBuild" | |
| target: "/opt/studue/releases/backend-1.1.0" | |
| - name: Restart | |
| uses: appleboy/ssh-action@v1 | |
| with: | |
| host: studue.ch | |
| key: ${{ secrets.DEPLOY_SSH_PRIVATE_KEY }} | |
| username: studue | |
| password: ${{ secrets.DEPLOY_SSH_PASSWORD }} | |
| script: sudo systemctl restart studue |