본문 바로가기

Server12

[AWS API Gateway] route key, route 경로 제외한 path를 통합으로 연결하기 구성 * AWS API Gateway(HTTP API) * ABL 통합, HTTP 통합 연결 문제 상황 * HTTP 통합 Routing ANY /domain/{proxy+} * ALB 통합 Routing ANY /app/{proxy+} 예를 들어 이렇게 구성되어 있다고 보자 HTTP에서 연결된 API는 실제로 /domain이라는 패스를 가지고 있지 않다. http://test.com/test 라는 패스를 가지고 있다. 이때, HTTP 통합은 http://test.com/{proxy} 이렇게 routing에서 사용한 proxy 변수를 이용함으로써 /domain을 제외하고 {proxy} 부분의 패스만 넘겨줄 수 있다. 이처럼 ALB에서도 /app을 제외한 {proxy+} 부분만 경로를 넘겨주고 싶을 때 파라.. 2023. 8. 30.
[AWS-SES/Spring]첨부파일 붙여서 메일 보내기 pom.xml 의존성 추가 com.amazonaws aws-java-sdk-ses 1.12.30 javax.mail mail 1.4 AwsSesConfig.class 작성 @Configuration public class AwsSesConfig { @Value("${aws.ses.access-key}") private String accessKey; @Value("${aws.ses.secret-key}") private String secretKey; @Bean public AmazonSimpleEmailService amazonSimpleEmailService() { final BasicAWSCredentials basicAWSCredentials = new BasicAWSCredentials(acce.. 2022. 1. 4.
Tomcat8.5 + SpringBoot CORS 문제 해결 환경은 SpringBoot의 내장톰캣을 이용하지 않고 톰캣 서버를 별도로 설치하여 그 안에서 스프링부트 앱을 올리는 구조였다. 프로젝트의 API를 프론트개발 쪽에서 호출해야 하는데 CORS 문제가 있어 Spring Security에서 CORS 관련 코드를 추가하여 해결했다. @Override protected void configure(HttpSecurity http) throws Exception { http ... .and() .cors().configurationSource(corsConfigurationSource()) .and() ... } @Bean public CorsConfigurationSource corsConfigurationSource() { CorsConfiguration conf.. 2021. 9. 10.
[Svelte 앱 S3, CloudFront에 배포하기] 3. CloudFront 연결하기 [Svelte 앱 S3, CloudFront에 배포하기] 2. S3 버킷에 배포하기 cloned sveltejs/template#HEAD to my-project $ ls my-project 2. svelte te.." data-og-host="12teamtoday.tistory.com" data-og-source-url="https://12teamtoday.tistory.com/136" data-og-url="https://12tea.. 12teamtoday.tistory.com 이번엔 지난번에 생성한 S3버킷과 CloudFront를 연결해보겠습니다. 그 전에 CloudFront는 무엇이냐 - AWS에서 제공하는 CDN(Content Delivery Network) 서비스입니다. - 전세계 AWS 리전.. 2021. 8. 23.