Skip to content

Commit 7cd555a

Browse files
authored
Update CDCI-master.yml - OFF Deploy
1 parent 3909dba commit 7cd555a

File tree

1 file changed

+27
-27
lines changed

1 file changed

+27
-27
lines changed

.github/workflows/CDCI-master.yml

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
- uses: actions/checkout@v3
1616
#JDK
1717
- name: Set up JDK 21
18-
uses: actions/setup-java@v3
18+
uses: actions/setup-java@v4
1919
with:
2020
java-version: '21'
2121
distribution: 'corretto'
@@ -69,35 +69,35 @@ jobs:
6969
contents: write
7070
steps:
7171
- uses: actions/checkout@v4
72-
- name: Set up JDK 17
72+
- name: Set up JDK 21
7373
uses: actions/setup-java@v4
7474
with:
75-
java-version: "17"
75+
java-version: "21"
7676
distribution: temurin
7777
- name: Generate and submit dependency graph
7878
uses: gradle/actions/dependency-submission@417ae3ccd767c252f5661f1ace9f835f9654f2b5
7979

80-
deploy:
81-
needs: build
82-
runs-on: ubuntu-latest
83-
if: github.ref == 'refs/heads/main'
84-
steps:
85-
- uses: actions/checkout@v3
86-
- name: Download artifacts
87-
uses: actions/download-artifact@v3
88-
with:
89-
name: build-output
90-
- name: Setup SSH key
91-
env:
92-
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
93-
SSH_KNOWN_HOSTS: ${{ secrets.SSH_KNOWN_HOSTS }}
94-
run: |
95-
mkdir -p ~/.ssh/
96-
echo "$SSH_PRIVATE_KEY" > ~/.ssh/id_rsa
97-
chmod 600 ~/.ssh/id_rsa
98-
echo "$SSH_KNOWN_HOSTS" > ~/.ssh/known_hosts
99-
chmod 644 ~/.ssh/known_hosts
100-
- name: Deploy to Server
101-
run: |
102-
scp -o StrictHostKeyChecking=no build/libs/*.jar user@server:/path/to/project/
103-
ssh user@server "cd /path/to/project && java -jar your-app.jar &"
80+
#deploy:
81+
#needs: build
82+
#runs-on: ubuntu-latest
83+
#if: github.ref == 'refs/heads/main'
84+
#steps:
85+
#- uses: actions/checkout@v4
86+
#- name: Download artifacts
87+
#uses: actions/download-artifact@v3
88+
#with:
89+
#name: build-output
90+
#- name: Setup SSH key
91+
#env:
92+
#SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
93+
#SSH_KNOWN_HOSTS: ${{ secrets.SSH_KNOWN_HOSTS }}
94+
#run: |
95+
#mkdir -p ~/.ssh/
96+
#echo "$SSH_PRIVATE_KEY" > ~/.ssh/id_rsa
97+
#chmod 600 ~/.ssh/id_rsa
98+
#echo "$SSH_KNOWN_HOSTS" > ~/.ssh/known_hosts
99+
#chmod 644 ~/.ssh/known_hosts
100+
#- name: Deploy to Server
101+
#run: |
102+
#scp -o StrictHostKeyChecking=no build/libs/*.jar user@server:/path/to/project/
103+
#ssh user@server "cd /path/to/project && java -jar your-app.jar &"*/

0 commit comments

Comments
 (0)