Skip to content

Merge branch 'development' #43

Merge branch 'development'

Merge branch 'development' #43

Workflow file for this run

name: Deploy
on:
push:
branches: [ master ]
jobs:
build:
name: Build
uses: Cadiducho/CadiBot/.github/workflows/gradle.yml@master
with:
jdk_version: 21
deploy:
name: Deploy
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v3
with:
name: cadibot-distribution
- run: ls -lah
- name: 🚀 Upload new artifact
uses: appleboy/[email protected]
with:
host: ${{ secrets.SECRET_PRODUCTION_HOST }}
username: ${{ secrets.SECRET_PRODUCTION_USER }}
key: ${{ secrets.SECRET_PRODUCTION_RSA }}
port: ${{ secrets.SECRET_PRODUCTION_PORT }}
source: "Cadibot.zip"
target: ${{ secrets.SECRET_PRODUCTION_PATH }}
- name: 🔨 Deploy & Restart server
uses: appleboy/[email protected]
with:
host: ${{ secrets.SECRET_PRODUCTION_HOST }}
username: ${{ secrets.SECRET_PRODUCTION_USER }}
key: ${{ secrets.SECRET_PRODUCTION_RSA }}
port: ${{ secrets.SECRET_PRODUCTION_PORT }}
script: |
cd ${{ secrets.SECRET_PRODUCTION_PATH }}
./cleanOld.sh
./extractArtifact.sh
./reboot.sh