Skip to content

Commit

Permalink
✅ [MOD] 배포 환경에서 로그 기록
Browse files Browse the repository at this point in the history
  • Loading branch information
jaejlf committed Aug 16, 2022
1 parent 3e440d4 commit c6abbfa
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions scripts/deploy.sh
Expand Up @@ -33,4 +33,5 @@ echo "> JAR Name: $JAR_NAME"

nohup java -jar \
-Dspring.config.location=classpath:/application.properties,/home/ec2-user/app/application-db.properties,/home/ec2-user/app/application-s3.properties,/home/ec2-user/app/application-email.properties \
-Dspring.profiles.active=prod \
$JAR_NAME > $REPOSITORY/nohup.out 2>&1 &
10 changes: 5 additions & 5 deletions src/main/resources/logback-spring.xml
Expand Up @@ -4,13 +4,13 @@
<include resource="org/springframework/boot/logging/logback/console-appender.xml"/>

<property name="LOG_FILE_NAME" value="logback"/>
<property name="LOG_DEBUG_PATH" value="/home/ec2-user/app/step2/logs/debug"/>
<property name="LOG_HIBERNATE_PATH" value="/home/ec2-user/app/step2/logs/hibernate"/>
<property name="LOG_API_PATH" value="/home/ec2-user/app/step2/logs/apis"/>
<property name="LOG_ERROR_PATH" value="/home/ec2-user/app/step2/logs/error"/>
<property name="LOG_DEBUG_PATH" value="/home/ec2-user/app/logs/debug"/>
<property name="LOG_HIBERNATE_PATH" value="/home/ec2-user/app/logs/hibernate"/>
<property name="LOG_API_PATH" value="/home/ec2-user/app/logs/apis"/>
<property name="LOG_ERROR_PATH" value="/home/ec2-user/app/logs/error"/>

<springProfile name="local">
<root level="DEBUG">
<root level="INFO">
<appender-ref ref="CONSOLE"/>
</root>
</springProfile>
Expand Down

0 comments on commit c6abbfa

Please sign in to comment.