Skip to content

Commit

Permalink
github actions test
Browse files Browse the repository at this point in the history
  • Loading branch information
airoca committed Jan 23, 2024
1 parent feb8bf7 commit 7cfe4d6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,18 +27,18 @@ jobs:
run: docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }}

- name: Build Docker Image
run: docker build -t yh0872/springboot-example .
run: docker build -t yh0872/signal .

- name: Publish Image to Docker Hub
run: docker push yh0872/springboot-example:latest
run: docker push yh0872/signal:latest

deploy:
needs: build
runs-on: [aws-ec2]
steps:
- name: Pull Image from docker hub
run: sudo docker pull yh0872/springboot-example:latest
run: sudo docker pull yh0872/signal:latest
- name: Delete old container
run: sudo docker rm -f springboot-example-container
run: sudo docker rm -f signal-container
- name: Run docker container
run: sudo docker run -d -p 8080:8080 --name springboot-example-container yh0872/springboot-example
run: sudo docker run -d -p 8080:8080 --name signal-container yh0872/signal
2 changes: 1 addition & 1 deletion src/main/resources/application.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
spring:
datasource:
url: jdbc:mysql://192.249.29.26:3306/sign
url: jdbc:mysql://192.249.29.56:3306/sign
username: testuser
password: rj7783208232
jpa:
Expand Down

0 comments on commit 7cfe4d6

Please sign in to comment.