Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weโ€™ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

๐Ÿ’š Ci : release ์ธํ”„๋ผ application.yml profile ๋ถ„๋ฆฌ #72

Merged
merged 1 commit into from
Oct 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions .ebextensions-release/00-makeFiles.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
files:
"/sbin/appstart" :
mode: "000755"
owner: webapp
group: webapp
content: |
#!/usr/bin/env bash
JAR_PATH=/var/app/current/application.jar

# run app
killall java
java -Dfile.encoding=UTF-8 -Dspring.profiles.active=release -jar $JAR_PATH
3 changes: 3 additions & 0 deletions .ebextensions-release/01-set-timezone.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
commands:
set_time_zone:
command: ln -f -s /usr/share/zoneinfo/Asia/Seoul /etc/localtime
2 changes: 1 addition & 1 deletion .github/workflows/release_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
mkdir -p deploy
cp build/libs/*.jar deploy/application.jar
cp Procfile deploy/Procfile
cp -r .ebextensions deploy/.ebextensions
cp -r .ebextensions-release deploy/.ebextensions
cp -r .platform deploy/.platform
cd deploy && zip -r deploy.zip .

Expand Down
41 changes: 41 additions & 0 deletions src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,3 +91,44 @@ openai:
token: ${OPEN_API_TOKEN}
url:
chat: https://api.openai.com/v1/chat/completions

---
spring:
config:
activate:
on-profile: release
datasource:
username: ${aws.db.username}
password: ${aws.db.password}
url: ${aws.db.url}
driver-class-name: com.mysql.cj.jdbc.Driver
sql:
init:
mode: never
jpa:
properties:
hibernate:
dialect: org.hibernate.dialect.MySQLDialect
# show_sql: true
# format_sql: true
use_sql_comments: true
hbm2ddl:
auto: update
default_batch_fetch_size: 1000
data:
redis:
host: briefing-redis-cluster.0ot2cs.ng.0001.apn2.cache.amazonaws.com
port: 6379
jwt:
header: Authorization
# dev server
secret: ${JWT_SECRET}
# secret : ${JWT_SECRET}
authorities-key: authoritiesKey
access-token-validity-in-seconds: 1210000000 # 30 m
refresh-token-validity-in-seconds: 1210000000 # 14 d

openai:
token: ${OPEN_API_TOKEN}
url:
chat: https://api.openai.com/v1/chat/completions
Loading