Skip to content

Commit

Permalink
Merge pull request #189 from YogitTeam/feat/report
Browse files Browse the repository at this point in the history
#98 feat: 배포용 apns p12파일 추가 및 적용
  • Loading branch information
xhaktmchl authored Apr 16, 2023
2 parents 1ac63b7 + d6bb027 commit 21da44b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
1 change: 1 addition & 0 deletions server/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,4 @@ AuthKey_QLHFNT37VK.p8
application.properties
application.yml
Certificates.p12
Certificates_prod.p12
16 changes: 8 additions & 8 deletions server/src/main/java/com/yogit/server/config/APNsConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ public ApnsClient someAppDevApnsClient(@Value("${APN.DEV.P12.PW}") String DEV_PW
.build();
}

// @Bean
// public ApnsClient someAppProdApnsClient() throws IOException {
// // 배표용 인증 키 파일
// return new ApnsClientBuilder()
// .setApnsServer(ApnsClientBuilder.PRODUCTION_APNS_HOST)
// .setClientCredentials(new ClassPathResource("some_app_prod_pkcs_12_file.p12").getInputStream(), "some_app_prod_password")
// .build();
// }
@Bean
public ApnsClient someAppProdApnsClient(@Value("${APN.PROD.P12.PW}") String PROD_PW, @Value("${APN.PROD.CERTIFICATE.PATH}") String PROD_CERTIFICATE_PATH) throws IOException {
// 배표용 인증 키 파일
return new ApnsClientBuilder()
.setApnsServer(ApnsClientBuilder.PRODUCTION_APNS_HOST)
.setClientCredentials(new ClassPathResource(PROD_CERTIFICATE_PATH).getInputStream(), PROD_PW)
.build();
}

}

0 comments on commit 21da44b

Please sign in to comment.