
application-prod.yml
server:
port: 8080
spring:
thymeleaf:
prefix: "classpath:templates/"
suffix: ".html"
datasource:
url: jdbc:postgresql://183.107.106.241:40010/aisjam
username: ajsjam_user1
password:
driver-class-name: org.postgresql.Driver
jpa:
hibernate:
ddl-auto: update
show-sql: true
properties:
hibernate:
dialect: org.hibernate.dialect.PostgreSQLDialect
mybatis:
mapper-locations: classpath:mapper/*.xml
# configuration:
# log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
application-test.yml
server:
port: 8080
spring:
thymeleaf:
prefix: "classpath:templates/"
suffix: ".html"
datasource:
url: jdbc:postgresql://192.168.0.219:21901/aissample
username: bukwon
password:
driver-class-name: org.postgresql.Driver
# 테스트용
jpa:
hibernate:
ddl-auto: create
show-sql: true
properties:
hibernate:
dialect: org.hibernate.dialect.PostgreSQLDialect
mybatis:
mapper-locations: classpath:mapper/*.xml
# configuration:
# log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
application.yml
spring:
profiles:
active: test
gitaction.yml
- name: Build with Maven
run: mvn -B package --file pom.xml -Dspring.profiles.active=prod
... 다른 내용들 ...
- name: Load and run Docker container on remote server
run: |
ssh -p 50022 ${{ secrets.SSH_USER }}@${{ secrets.SERVER_IP }} "
docker load -i /home/bluemap/dev2/dev2-aisjam/aisjam-image.tar &&
docker stop dev2-aisjam || true &&
docker rm dev2-aisjam || true &&
docker run -d -p 20210:8080 --name dev2-aisjam -e SPRING_PROFILES_ACTIVE=prod aisjam-image
"