From 9a5ee6153e51bf8ed3f861140a3c1c7d2baa1116 Mon Sep 17 00:00:00 2001 From: "H. Utku Maden" Date: Sat, 25 Jan 2025 19:17:58 +0300 Subject: [PATCH] Create deploy.yaml --- .gitea/workflows/deploy.yaml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .gitea/workflows/deploy.yaml diff --git a/.gitea/workflows/deploy.yaml b/.gitea/workflows/deploy.yaml new file mode 100644 index 0000000..a4669ef --- /dev/null +++ b/.gitea/workflows/deploy.yaml @@ -0,0 +1,31 @@ +name: Build and Deploy +on: + push: + branches: + - master + workflow_dispatch: +jobs: + build_and_deploy: + runs-on: ubuntu-latest + container: + image: mcr.microsoft.com/devcontainers/dotnet + steps: + - name: Install prerequisites + run: dotnet tool update -g docfx + - name: Checkout Repository + uses: actions/checkout@v4 + with: + submodules: recursive + - name: Compile Web Pages + run: docfx + - name: SFTP Deploy + uses: wlixcc/SFTP-Deploy-Action@v1.2.5 + with: + username: '${{ vars.SSH_USER }}' + server: '${{ vars.SSH_SERVER }}' + port: '${{ vars.SSH_PORT }}' + ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }} + local_path: './_site/*' + remote_path: '${{ vars.DESTINATION }}' + sftpArgs: -o ConnectTimeout=10 + rsyncArgs: --exclude=.* \ No newline at end of file