Skip to content

chore(deps): update dependency gradle to v8.12 #668

chore(deps): update dependency gradle to v8.12

chore(deps): update dependency gradle to v8.12 #668

Workflow file for this run

name: backend-push
on:
push:
paths:
- 'backend/**'
- '.github/workflows/backend-push.yml'
jobs:
backend-push:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: gradle/wrapper-validation-action@v3
- name: Set up JDK 11
uses: actions/setup-java@v4
with:
java-version: '11'
distribution: 'adopt'
cache: gradle
- name: Build and test
run: |
cd backend
./gradlew build
- name: Setup SSH, copy over SSH and activate
if: github.ref_name == 'master' || github.ref_name == 'main'
run: |
mkdir -p ~/.ssh/
echo "${{ secrets.GCE_RSA_KEY }}" > /tmp/id_rsa
sudo chmod 600 /tmp/id_rsa
echo "${{ secrets.GCE_KNOWN_HOSTS }}" > ~/.ssh/known_hosts
scp -i /tmp/id_rsa backend/build/libs/kalkulierbar-backend-all.jar [email protected]:kalkulierbar/fresh.jar
ssh -i /tmp/id_rsa [email protected] 'mv kalkulierbar/fresh.jar kalkulierbar/production.jar && sudo systemctl restart kalkulierbar'
- name: Cleanup Gradle Cache
run: |
rm -f ~/.gradle/caches/modules-2/modules-2.lock
rm -f ~/.gradle/caches/modules-2/gc.properties