copy content to local server
All checks were successful
Gitea Action Maven build / build (push) Successful in 48s
Gitea Action Maven build / deploy (push) Successful in 6s

This commit is contained in:
Eduard Kuksa 2025-02-13 22:08:55 +07:00
parent 5d021615c9
commit 883917c79e

View File

@ -22,15 +22,14 @@ jobs:
cache: 'maven'
- name: Build, Test and Package with Maven
run: mvn -B verify --file pom.xml -e
- name: List Target Directory Contents
run: ls -l target/
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: app-artifacts
name: app-artifact
path: |
target/*.jar
Dockerfile
docker-compose.yml
- name: Create Maven settings.xml
run: |
cat <<EOF > ~/.m2/settings.xml
@ -55,10 +54,8 @@ jobs:
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: app-artifacts
name: app-artifact
path: artifact
- name: List Artifact Contents
run: ls -l artifact/
- name: Install SSH Key
uses: shimataro/ssh-key-action@v2
with:
@ -68,6 +65,6 @@ jobs:
run: |
scp artifact/target/*.jar ${{ vars.DEPLOY_USER }}@${{ vars.DEPLOY_HOST }}:${{ vars.DEPLOY_PATH }}
scp artifact/Dockerfile ${{ vars.DEPLOY_USER }}@${{ vars.DEPLOY_HOST }}:${{ vars.DEPLOY_PATH }}
# scp docker-compose.yml ${{ vars.DEPLOY_USER }}@${{ vars.DEPLOY_HOST }}:${{ vars.DEPLOY_PATH }}
scp artifact/docker-compose.yml ${{ vars.DEPLOY_USER }}@${{ vars.DEPLOY_HOST }}:${{ vars.DEPLOY_PATH }}