75 Commits

Author SHA1 Message Date
eGovFrameSupport
ab8b150739 Update StatisticsRepository.java 2024-12-17 17:08:10 +09:00
eGovFrameSupport
b4d3eb0da3 Update RoleRepository.java 2024-12-17 17:07:27 +09:00
overpassion
d09bcffdd8 Merge pull request #25 from s-yujin1004/contribution
Kubernetes v1.28 기준으로 수정
2024-10-08 16:17:06 +09:00
overpassion
c64a5917fe Merge pull request #24 from LeeBaekHaeng/2024/problems/user-service
[user-service] 이클립스 문제(Problems) 해결
2024-10-08 16:13:25 +09:00
overpassion
cc550b5476 Merge pull request #22 from LeeBaekHaeng/2024/problems/SecurityConfig
[SecurityConfig] 이클립스 문제(Problems) 해결
2024-10-08 09:50:33 +09:00
overpassion
20608cb79f Merge pull request #23 from LeeBaekHaeng/2024/problems/apigateway
[apigateway] 이클립스 문제(Problems) 해결
2024-10-08 09:42:50 +09:00
overpassion
7fa693cf7a Merge pull request #20 from yooniank/contribution
chore: update README.md for k8s
2024-10-07 17:46:57 +09:00
overpassion
53eef65e2f Merge branch 'contribution' into contribution 2024-10-07 17:46:48 +09:00
overpassion
4935214321 Merge pull request #17 from dasomel/contribution
띄어쓰기 수정
2024-10-07 17:25:18 +09:00
steve jobs
a6ee514cd4 Kubernetes v1.28 기준으로 수정 2024-09-27 11:03:18 +09:00
이백행
0823147573 [user-service] 이클립스 문제(Problems) 해결 2024-09-25 10:39:45 +09:00
이백행
729f3bfaf4 [apigateway] 이클립스 문제(Problems) 해결 2024-09-24 21:41:19 +09:00
이백행
fbe5cd8521 [SecurityConfig] 이클립스 문제(Problems) 해결 2024-09-23 21:10:56 +09:00
yooniank
26fbd581da chore: update README.md for k8s 2024-09-20 10:41:58 +00:00
dasomel
edb712aec5 띄어쓰기 수정
Deployenvironments -> Deploy environments
2024-07-17 23:02:33 +09:00
egovframesupport
b2f3854ad3 Doc: contribution 용 issue template 등록 2024-07-15 09:38:33 +09:00
jei007
43f0351bda Update ReserveCheckSeviceApplication.java 2024-02-29 10:36:10 +09:00
jei007
772870c618 Update build.gradle 2024-02-29 10:34:51 +09:00
jei007
60413ff330 Update build.gradle 2024-02-29 10:23:33 +09:00
jei007
90aad445eb Update logback-spring.xml 2024-02-29 10:21:37 +09:00
jei007
57eae5a411 Update build.gradle 2024-02-29 10:20:28 +09:00
jei007
a2bb69217c Update logback-spring.xml 2024-02-29 10:18:07 +09:00
jei007
a12cdaa798 Update build.gradle 2024-02-29 10:16:26 +09:00
jei007
25ab6a7140 Update build.gradle 2024-02-29 10:15:44 +09:00
jei007
cb776dc0ab Update logback-spring.xml 2024-02-29 10:13:15 +09:00
jei007
7b7dd253e9 Update build.gradle 2024-02-29 10:12:18 +09:00
jei007
7fa8db7334 Update logback-spring.xml 2024-02-29 10:08:02 +09:00
jei007
2ecdb074cd Update build.gradle 2024-02-29 10:06:32 +09:00
jei007
7b155b3c0b Update logback-spring.xml 2024-02-29 10:02:05 +09:00
jei007
0a48c563c6 Update build.gradle 2024-02-29 10:01:07 +09:00
jei007
b6c2872ac8 Update build.gradle 2024-02-29 09:27:45 +09:00
jei007
bf5494cffe Update build.gradle 2024-02-29 09:25:49 +09:00
jei007
ae418ce420 Update logback-spring.xml 2024-02-29 09:24:25 +09:00
jei007
7dad5c8742 Update build.gradle 2024-02-29 09:23:11 +09:00
jei007
ed5671189c Update logback-spring.xml 2024-02-29 09:16:26 +09:00
jei007
c0981885e0 Update logback-spring.xml 2024-02-29 09:15:25 +09:00
jei007
27200749eb Update build.gradle 2024-02-29 09:14:31 +09:00
eGovFrameSupport
0550fe4965 Update pull_request_template.md
캡쳐 -> 캡처
2023-09-07 17:37:41 +09:00
eGovFrameSupport
510089fdf7 Create LICENSE 2023-07-07 13:39:10 +09:00
overpassion
f72d8542dd Merge pull request #14 from miniplugin/contribution
윈도우 시스템에서도 다국어 메세지 경로를 사용 및  포털사이트의 묻고답하기 신규 등록시 첨부파일 업로드의 post 테이블에 attachmentCode 누락되는 부분 처리
2023-06-12 14:20:03 +09:00
kimilguk
9086c60482 커밋7. 넥스트js 포털사이트(대규모)의 배너 출력 시 타이클과 더보기 링크가 밝은 색상에서도 보이게 css처리 2023-06-06 15:30:42 +09:00
kimilguk
6ac1790f2f 커밋6. 넥스트js 포털사이트의 묻고답하기 신규 등록시 첨부파일 업로드의 post 테이블에 attachmentCode 누락되는 부분 추가 2023-06-06 13:57:54 +09:00
kimilguk
b2b23f7b5e 커밋5. 넥스트js 포털사이트의 배너 출력 시 타이클과 더보기 링크가 밝은 색상에서도 보이게 css처리 2023-06-06 13:52:48 +09:00
kimilguk
96098869a8 커밋4. 포털 실행 방법 ts-node로 시작하게 변화: 실행 속도 향상 2023-06-06 13:31:22 +09:00
kimilguk
3af8a46d83 커밋3. 윈도우 시스템에서도 업로드 시 Temp폴더의 delete file 에러방지코드 추가 2023-06-06 13:24:39 +09:00
kimilguk
b2adbc1079 커밋2. 윈도우 시스템에서도 파일스토리지의 경로를 사용가능하게 추가 2023-06-06 13:20:57 +09:00
kimilguk
81c6c93d2a 커밋1. 윈도우 시스템에서도 다국어 메세지 경로를 사용 가능하게 추가 2023-06-06 12:58:57 +09:00
overpassion
0fb4003417 Merge pull request #13 from lucki3377/contribution
SecurityConfig에서 WebSecurityConfigurerAdapter 대체 처리
2023-06-05 14:16:00 +09:00
overpassion
d2875cfacb Merge pull request #12 from miniplugin/contribution
윈도우시스템에서도 웹에디터로 올린 이미지를 볼수있게 코드추가 및 MySql Closed방지
2023-06-05 09:49:12 +09:00
lucki3377
50d19be98f Update SecurityConfig.java
spring boot 2.7 버전 업그레이드로 인한 deperated된 소스 처리
2023-05-31 16:25:35 +09:00
kimilguk
342b66cfca 윈도우시스템에서도 웹에디터로 올린 이미지를 볼수있게 코드추가 및 MySql Closed방지 2023-05-12 16:45:21 +09:00
overpassion
dcbe48d308 Update package-lock.json
원복처리
2023-05-12 09:12:00 +09:00
overpassion
f9ca7b8905 Create package-lock.json
삭제파일 복원
2023-05-11 17:16:50 +09:00
overpassion
4cbecb2686 Merge pull request #11 from miniplugin/contribution
프런트엔드 admin 실행 스크립트에 windows용 추가 및 npm 의존성 버전 매뉴얼대로 실행
2023-05-11 17:04:30 +09:00
overpassion
9f7a53a860 Delete package-lock.json
삭제처리
2023-05-11 16:53:31 +09:00
overpassion
fb2434a25b Update package-lock.json
package-lock.json 원복 처리
2023-05-11 16:52:50 +09:00
overpassion
0febd840b2 Update package.json
코드 수정
2023-05-11 16:25:54 +09:00
boramcom
3f04f5f07d 프런트엔드 admin 실행 스크립트에 windows용 추가 및 npm 의존성 버전 매뉴얼대로 실행 2023-05-02 17:26:46 +09:00
overpassion
d4e159b1dd Merge pull request #10 from miniplugin/contribution
MSA 백엔드 프로젝트 중 5개의 application.yml 파일이 EUC-KR 로 인코딩 된 부분 UTF-8로 변경
2023-05-02 14:55:31 +09:00
boramcom
5e16e6cdc8 MSA 백엔드 프로젝트 중 5개의 application.yml 파일이 EUC-KR 로 인코딩 된 부분 UTF-8로 변경 2023-04-29 18:19:11 +09:00
chris-yoon
97a717796d Merge pull request #9 from yoonian/split-languages
Split English into README-en.md
2023-04-24 13:32:20 +09:00
Yoon PyungHo
181057d1fe Split English into README-en.md 2023-04-20 16:49:00 +00:00
chris-yoon
18ad94ec8a Merge pull request #8 from eGovFramework/main
Main
2023-04-17 13:41:27 +09:00
chris-yoon
8c1401b6c0 Merge pull request #2 from yoonian/add-kustomize
add: kustomize
2023-04-17 12:52:47 +09:00
Chris Yoon
c6d961992d README 영문 수정 2023-03-28 15:48:09 +09:00
Chris Yoon
5d50f46bc5 영문 추가 2023-03-28 15:40:29 +09:00
Chris Yoon
43682454e5 교육교재 2023-03-28 14:00:52 +09:00
Chris Yoon
4cec70760e 디렉토리 설명 추가 2023-03-28 13:58:55 +09:00
chris-yoon
491f0cdaec Update README.md
교육교재 업로드
2023-03-28 11:31:15 +09:00
Chris Yoon
e9326f2eb2 이미지경로 2023-03-28 11:28:04 +09:00
Chris Yoon
5a0005c291 설명 보충 2023-03-28 11:25:05 +09:00
Chris Yoon
aae34bb339 badges, directory structure, how to install 2023-03-28 10:24:33 +09:00
yongfire38
83f1c1047b Doc: 영문 추가 2023-03-24 13:52:15 +09:00
yongfire38
d230341909 Docs: PR template / issue template 추가 2023-03-20 14:47:41 +09:00
PyungHo Yoon
832e63ed3d add: kustomize 2022-07-14 02:39:06 +09:00
32 changed files with 503 additions and 315 deletions

View File

@@ -1,35 +0,0 @@
name: 개발가이드 수정 요청 Requesting changes to the development guide
description: 개발가이드 수정 요청하는 템플릿입니다. Template for requesting changes to the dev guide.
title: "[Guide]: "
labels: ["guide"]
assignees:
- overpassion
body:
- type: markdown
attributes:
value: |
시간을 내어 개발가이드 수정 요청을 작성해 주셔서 감사합니다. Thank you for taking the time to fill out a DevGuide correction request. (공유하고 싶은 기술문서나 노하우는 github wiki에 남겨 주세요. If you have any documentation or know-how you'd like to share, please leave it on our github wiki.)
- type: input
id: url
attributes:
label: 개발가이드 URL Dev Guide URL
description: 수정해야할 개발가이드 URL을 적어 주세요. Please write down the dev guide URL that needs to be modified.
placeholder: Example) https://www.egovframe.go.kr/wiki/doku.php?id=egovframework:rte4.1:fdl:aop:aspectj
validations:
required: true
- type: textarea
id: where-to-amend
attributes:
label: 수정 대상 내용 What to fix
description: 수정해야할 대상 내용을 기입해 주세요. Fill in what you need to fix.
placeholder: 수정해야할 대상은 다음과 같습니다. Here's what you'll need to modify
validations:
required: true
- type: textarea
id: amendment
attributes:
label: 수정 문구 Corrective Wording
description: 어떻게 수정되어야 하는지 적어주세요. Please write down how it should be fixed.
placeholder: 다음과 같이 수정되어야 합니다. It should be modified as follows
validations:
required: true

View File

@@ -3,7 +3,7 @@ description: 오류 내용을 이슈로 등록하는 템플릿입니다. Templat
title: "[Bug]: " title: "[Bug]: "
labels: ["bug", "triage"] labels: ["bug", "triage"]
assignees: assignees:
- overpassion - rukegithub
body: body:
- type: markdown - type: markdown
attributes: attributes:

View File

@@ -1,9 +1,9 @@
name: 기능 요구 및 의견 Feature Request name: 기능 요구 Feature Request
description: 기능 요구나 기타 의견을 이슈로 등록하는 템플릿입니다. Suggest an idea for improving eGovFrame. description: 기능 요구 이슈로 등록하는 템플릿입니다. Suggest a new feature for improving eGovFrame.
title: "[기능요구(Feature)]: " title: "[기능요구(Feature)]: "
labels: ["feature"] labels: ["feature"]
assignees: assignees:
- overpassion - rukegithub
body: body:
- type: markdown - type: markdown
attributes: attributes:

View File

@@ -0,0 +1,55 @@
name: 발전 방안 제안 Improvement Plan
description: 발전 방안을 이슈로 등록하는 템플릿입니다. Suggest a new plan for improving eGovFrame.
title: "[발전 방안 제안(Improvement Plan)]: "
labels: ["Improvement"]
assignees:
- yongfire38
body:
- type: markdown
attributes:
value: |
시간을 내어 의견을 작성해 주셔서 감사합니다. Thank you for taking the time to fill out a request.
- type: input
id: idea-name
attributes:
label: 아이디어명 Idea Name
validations:
required: true
- type: textarea
id: idea-summary
attributes:
label: 아이디어 요약 Idea Summary
description: 과제 내용을 300자 이내로 간결하게 요약 및 정의해 주세요 Please summarize and define your content in 300 characters or less
placeholder: 예) 게시판 첨부기능 추가 Example) Adding a bulletin board attachment
validations:
required: true
- type: textarea
id: suggestion-background
attributes:
label: 제안배경 Suggestion Background
description: 아이디어를 제안하게 된 배경 및 필요성을 기술해 주세요. Please describe the background and need for the idea.
placeholder: 아이디어를 제안하게 된 배경은 다음과 같습니다. The background to suggesting the idea is as follows.
validations:
required: true
- type: textarea
id: expectations
attributes:
label: 기대효과 Expectations
description: 아이디어의 실현 가능성과 예상되는 기대효과를 제시하여 주세요. Please describe the expected impact and outcome of the idea.
placeholder: 해당 아이디어의 기대효과는 다음과 같습니다. Here are the expected effects of this idea.
validations:
required: false
- type: textarea
id: free-writing
attributes:
label: 자유기술 Free Writing
description: 추가 기재하고 싶은 항목 및 내용을 자유롭게 기재하여 주세요. Please feel free to add anything else you'd like to include.
validations:
required: false
- type: textarea
id: reference
attributes:
label: 참고문헌 Reference
description: 참고문헌이 있는 경우 작성하여 주세요. If you have references, please include them.
validations:
required: false

View File

@@ -3,7 +3,6 @@ package org.egovframe.cloud.apigateway.api;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.context.MessageSource; import org.springframework.context.MessageSource;
import org.springframework.context.i18n.LocaleContextHolder;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
@@ -25,6 +24,7 @@ import java.util.Locale;
* 수정일 수정자 수정내용 * 수정일 수정자 수정내용
* ---------- -------- --------------------------- * ---------- -------- ---------------------------
* 2021/08/10 jaeyeolkim 최초 생성 * 2021/08/10 jaeyeolkim 최초 생성
* 2024/09/24 이백행 컨트리뷰션 이클립스 문제(Problems) 해결
* </pre> * </pre>
*/ */
@Slf4j @Slf4j

View File

@@ -6,8 +6,6 @@ import org.springframework.boot.web.error.ErrorAttributeOptions;
import org.springframework.boot.web.reactive.error.DefaultErrorAttributes; import org.springframework.boot.web.reactive.error.DefaultErrorAttributes;
import org.springframework.boot.web.reactive.error.ErrorAttributes; import org.springframework.boot.web.reactive.error.ErrorAttributes;
import org.springframework.context.MessageSource; import org.springframework.context.MessageSource;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.i18n.LocaleContextHolder; import org.springframework.context.i18n.LocaleContextHolder;
import org.springframework.web.reactive.function.server.ServerRequest; import org.springframework.web.reactive.function.server.ServerRequest;
@@ -31,6 +29,7 @@ import java.util.Map;
* 수정일 수정자 수정내용 * 수정일 수정자 수정내용
* ---------- -------- --------------------------- * ---------- -------- ---------------------------
* 2021/07/16 jaeyeolkim 최초 생성 * 2021/07/16 jaeyeolkim 최초 생성
* 2024/09/24 이백행 컨트리뷰션 이클립스 문제(Problems) 해결
* </pre> * </pre>
*/ */
@Slf4j @Slf4j

View File

@@ -1,8 +1,9 @@
package org.egovframe.cloud.discovery; package org.egovframe.cloud.discovery;
import org.springframework.context.annotation.Bean;
import org.springframework.security.config.annotation.web.builders.HttpSecurity; import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity; import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter; import org.springframework.security.web.SecurityFilterChain;
/** /**
* org.egovframe.cloud.discovery.SecurityConfig * org.egovframe.cloud.discovery.SecurityConfig
@@ -20,10 +21,11 @@ import org.springframework.security.config.annotation.web.configuration.WebSecur
* 수정일 수정자 수정내용 * 수정일 수정자 수정내용
* ---------- -------- --------------------------- * ---------- -------- ---------------------------
* 2021/06/30 jaeyeolkim 최초 생성 * 2021/06/30 jaeyeolkim 최초 생성
* 2024/09/23 이백행 컨트리뷰션 이클립스 문제(Problems) 해결
* </pre> * </pre>
*/ */
@EnableWebSecurity // Spring Security 설정들을 활성화시켜 준다 @EnableWebSecurity // Spring Security 설정들을 활성화시켜 준다
public class SecurityConfig extends WebSecurityConfigurerAdapter { public class SecurityConfig {
/** /**
* 스프링 시큐리티 설정 * 스프링 시큐리티 설정
@@ -31,8 +33,8 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
* @param http * @param http
* @throws Exception * @throws Exception
*/ */
@Override @Bean
protected void configure(HttpSecurity http) throws Exception { public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Exception {
http http
.csrf().disable() .csrf().disable()
.headers().frameOptions().disable() .headers().frameOptions().disable()
@@ -42,6 +44,7 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
.anyRequest().authenticated() .anyRequest().authenticated()
.and() .and()
.httpBasic(); .httpBasic();
return http.build();
} }
} }

View File

@@ -30,6 +30,7 @@ import java.util.Collections;
* 수정일 수정자 수정내용 * 수정일 수정자 수정내용
* ---------- -------- --------------------------- * ---------- -------- ---------------------------
* 2021/06/30 jaeyeolkim 최초 생성 * 2021/06/30 jaeyeolkim 최초 생성
* 2024/09/25 이백행 컨트리뷰션 이클립스 문제(Problems) 해결
* </pre> * </pre>
*/ */
@RequiredArgsConstructor @RequiredArgsConstructor
@@ -47,7 +48,8 @@ public class CustomOAuth2UserService implements OAuth2UserService<OAuth2UserRequ
*/ */
@Override @Override
public OAuth2User loadUser(OAuth2UserRequest userRequest) throws OAuth2AuthenticationException { public OAuth2User loadUser(OAuth2UserRequest userRequest) throws OAuth2AuthenticationException {
OAuth2UserService delegate = new DefaultOAuth2UserService(); // OAuth2UserService delegate = new DefaultOAuth2UserService();
OAuth2UserService<OAuth2UserRequest, OAuth2User> delegate = new DefaultOAuth2UserService();
OAuth2User oAuth2User = delegate.loadUser(userRequest); OAuth2User oAuth2User = delegate.loadUser(userRequest);
// 현재 로그인 진행 중인 서비스를 구분하는 코드(구글 or 네이버..) // 현재 로그인 진행 중인 서비스를 구분하는 코드(구글 or 네이버..)

View File

@@ -26,6 +26,10 @@ import java.io.Serializable;
*/ */
@Getter @Getter
public class SessionUser implements Serializable { public class SessionUser implements Serializable {
/**
*
*/
private static final long serialVersionUID = -6319235143325686744L;
private String userName; private String userName;
private String email; private String email;

View File

@@ -70,6 +70,9 @@ public class AuthorizationService extends AbstractService {
* @return Page<AuthorizationListResponseDto> 페이지 인가 목록 응답 DTO * @return Page<AuthorizationListResponseDto> 페이지 인가 목록 응답 DTO
*/ */
public Page<AuthorizationListResponseDto> findPage(RequestDto requestDto, Pageable pageable) { public Page<AuthorizationListResponseDto> findPage(RequestDto requestDto, Pageable pageable) {
if (log.isDebugEnabled()) {
log.debug("requestDto={}", requestDto);
}
return authorizationRepository.findPage(requestDto, pageable); return authorizationRepository.findPage(requestDto, pageable);
} }

View File

@@ -807,51 +807,51 @@ public class UserService extends AbstractService implements UserDetailsService {
return user.orElse(null); return user.orElse(null);
} }
/** // /**
* 소셜 사용자 엔티티 조회 // * 소셜 사용자 엔티티 조회
* 등록되어 있지 않은 경우 사용자 등록 // * 등록되어 있지 않은 경우 사용자 등록
* // *
* @param providerCode 공급자 코드 // * @param providerCode 공급자 코드
* @param providerId 공급자 id // * @param providerId 공급자 id
* @param email 이메일 // * @param email 이메일
* @param userName 사용자 명 // * @param userName 사용자 명
* @return UserLoginRequestDto 사용자 로그인 요청 DTO // * @return UserLoginRequestDto 사용자 로그인 요청 DTO
*/ // */
private UserResponseDto getAndSaveSocialUser(String providerCode, String providerId, String email, String userName) { // private UserResponseDto getAndSaveSocialUser(String providerCode, String providerId, String email, String userName) {
User user = findSocialUser(providerCode, providerId); // User user = findSocialUser(providerCode, providerId);
//
// 이메일로 조회 // // 이메일로 조회
// 공급자에서 동일한 이메일을 사용할 수 있고 // // 공급자에서 동일한 이메일을 사용할 수 있고
// 현재 시스템 구조 상 이메일을 사용자 식별키로 사용하고 있어서 이메일로 사용자를 한번 더 검색한다. // // 현재 시스템 구조 상 이메일을 사용자 식별키로 사용하고 있어서 이메일로 사용자를 한번 더 검색한다.
if (user == null) { // if (user == null) {
user = userRepository.findByEmail(email).orElse(null); // user = userRepository.findByEmail(email).orElse(null);
//
// 공급자 id로 조회되지 않지만 이메일로 조회되는 경우 공급자 id 등록 // // 공급자 id로 조회되지 않지만 이메일로 조회되는 경우 공급자 id 등록
if (user != null) { // if (user != null) {
user.setSocial(providerCode, providerId); // user.setSocial(providerCode, providerId);
} // }
} // }
//
if (user == null) { // if (user == null) {
// 사용자 등록 // // 사용자 등록
final String userId = UUID.randomUUID().toString(); // final String userId = UUID.randomUUID().toString();
//final String password = makeRandomPassword(); // 임의 비밀번호 생성 시 복호화 불가능 // //final String password = makeRandomPassword(); // 임의 비밀번호 생성 시 복호화 불가능
//
user = User.builder() // user = User.builder()
.email(email) // 100byte // .email(email) // 100byte
//.encryptedPassword(passwordEncoder.encode(password)) // 100 byte // //.encryptedPassword(passwordEncoder.encode(password)) // 100 byte
.userName(userName) // .userName(userName)
.userId(userId) // .userId(userId)
.role(Role.USER) // .role(Role.USER)
.userStateCode(UserStateCode.NORMAL.getKey()) // .userStateCode(UserStateCode.NORMAL.getKey())
.build(); // .build();
user.setSocial(providerCode, providerId); // user.setSocial(providerCode, providerId);
//
user = userRepository.save(user); // user = userRepository.save(user);
//
} // }
//
return new UserResponseDto(user); // return new UserResponseDto(user);
} // }
} }

View File

@@ -1,6 +1,5 @@
package org.egovframe.cloud.userservice.api.role; package org.egovframe.cloud.userservice.api.role;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.ObjectMapper;
import org.egovframe.cloud.userservice.api.role.dto.AuthorizationUpdateRequestDto; import org.egovframe.cloud.userservice.api.role.dto.AuthorizationUpdateRequestDto;
import org.egovframe.cloud.userservice.domain.role.Authorization; import org.egovframe.cloud.userservice.domain.role.Authorization;

View File

@@ -5,14 +5,11 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.web.client.TestRestTemplate; import org.springframework.boot.test.web.client.TestRestTemplate;
import org.springframework.context.MessageSource;
import java.util.Locale;
import org.springframework.test.context.ActiveProfiles; import org.springframework.test.context.ActiveProfiles;
import org.springframework.test.context.TestPropertySource; import org.springframework.test.context.TestPropertySource;
import static org.assertj.core.api.Assertions.assertThat; import static org.assertj.core.api.Assertions.assertThat;
import static org.springframework.boot.test.context.SpringBootTest.WebEnvironment.RANDOM_PORT;
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
@EnableConfigurationProperties @EnableConfigurationProperties

View File

@@ -30,6 +30,11 @@ import java.util.List;
public class RestResponsePage<T> extends PageImpl<T> { public class RestResponsePage<T> extends PageImpl<T> {
/** /**
*
*/
private static final long serialVersionUID = -5737360124251098346L;
/**
* Rest 응답 페이지 생성자 * Rest 응답 페이지 생성자
* *
* @param content 목록 * @param content 목록

77
k8s/README-en.md Normal file
View File

@@ -0,0 +1,77 @@
# Deploy services on Kubernetes
In Kubernetes, the service consists of two components,
1. Environments
2. Applications
And you can choose the storage in the application either NFS or Cinder provided by Openstack(used by [Pasta](http://paas-ta.kr))
# Prerequisites
## Install kustomize
If you are using kubectl 1.14 or later, it embeded kustomize. So please ignore this section.
I recommend that you install the latest version of [kubectl](https://kubectl.docs.kubernetes.io/installation/kubectl/) for your cluster instead of installing kustomize.
Even so, if you want to use kustomize, refer to [official kustomize doc](https://kustomize.io/).
# Deploy service
You must follow deployment order.
## Deploy environments
```sh
$ kustomize build k8s/environments | kubectl apply -f -
```
or if you are using the kubectl only,
```sh
$ kubectl apply -k k8s/environments
```
## Deploy applications
If you want to use NFS as a main storage,
```sh
$ kustomize build k8s/stoage/nfs | kubectl apply -f -
```
or
```sh
$ kubectl apply -k k8s/stoage/nfs
```
In case of using Openstack storage(CINDER) as a main storage,
```sh
$ kustomize build k8s/stoage/openstack | kubectl apply -f -
```
or
```sh
$ kubectl apply -k k8s/stoage/openstack
```
# Shutdown service
Simply apply deployment in reverse order.
If you are using nfs,
```sh
$ kustomize build k8s/environments | kubectl delete -f -
$ kustomize build k8s/stoage/nfs | kubectl delete -f - --wait
```
or
```sh
$ kubectl delete -k k8s/environments
$ kubectl delete -k k8s/stoage/nfs --wait
```
The case of openstack is similar, so it is omitted.

View File

@@ -1,77 +1,77 @@
# Deploy services on Kubernetes # Kubernetes에서 서비스 배포
In Kubernetes, the service consists of two components, Kubernetes에서 서비스는 두 가지 구성 요소로 이루어져 있습니다.
1. Environments 1. 환경 (Environments)
2. Applications 2. 애플리케이션 (Applications)
And you can choose the storage in the application either NFS or Cinder provided by Openstack(used by [Pasta](http://paas-ta.kr)) 그리고 애플리케이션에서 사용할 스토리지를 선택할 수 있으며, NFS 또는 Openstack이 제공하는 Cinder를 사용할 수 있습니다(이 경우 [PaaS-TA](http://paas-ta.kr)를 사용).
# Prerequisites # 사전 준비 {#prerequisites}
## Install kustomize ## kustomize 설치 {#install-kustomize}
If you are using kubectl 1.14 or later, it embeded kustomize. So please ignore this section. kubectl 1.14 이상을 사용하고 있다면, kustomize가 내장되어 있으므로 이 섹션을 무시해도 됩니다.
I recommend that you install the latest version of [kubectl](https://kubectl.docs.kubernetes.io/installation/kubectl/) for your cluster instead of installing kustomize. 대신 클러스터에서 최신 버전의 [kubectl](https://kubectl.docs.kubernetes.io/installation/kubectl/)을 설치하는 것을 권장합니다.
Even so, if you want to use kustomize, refer to [official kustomize doc](https://kustomize.io/). 그럼에도 불구하고 kustomize를 사용하고 싶다면, [공식 kustomize 문서](https://kustomize.io/)를 참고하세요.
# Deploy service # 서비스 배포 {#deploy-service}
You must follow deployment order. 배포 순서를 따라야 합니다.
## Deployenvironments ## 환경 배포 {#deploy-environments}
```sh ```sh
$ kustomize build k8s/environments | kubectl apply -f - $ kustomize build k8s/environments | kubectl apply -f -
``` ```
or if you are using the kubectl only, 혹은 kubectl만 사용하는 경우,
```sh ```sh
$ kubectl apply -k k8s/environments $ kubectl apply -k k8s/environments
``` ```
## Deploy applications ## 애플리케이션 배포 {#deploy-applications}
If you want to use NFS as a main storage, NFS를 메인 스토리지로 사용하려면,
```sh ```sh
$ kustomize build k8s/stoage/nfs | kubectl apply -f - $ kustomize build k8s/stoage/nfs | kubectl apply -f -
``` ```
or 혹은
```sh ```sh
$ kubectl apply -k k8s/stoage/nfs $ kubectl apply -k k8s/stoage/nfs
``` ```
In case of using Openstack storage(CINDER) as a main storage, Openstack의 스토리지(CINDER)를 메인 스토리지로 사용하는 경우,
```sh ```sh
$ kustomize build k8s/stoage/openstack | kubectl apply -f - $ kustomize build k8s/stoage/openstack | kubectl apply -f -
``` ```
or 혹은
```sh ```sh
$ kubectl apply -k k8s/stoage/openstack $ kubectl apply -k k8s/stoage/openstack
``` ```
# Shutdown service ## 서비스 종료 {#shutdown-service}
Simply apply deployment in reverse order. 단순히 배포 순서를 반대로 적용하면 됩니다.
If you are using nfs, NFS를 사용하는 경우,
```sh ```sh
$ kustomize build k8s/environments | kubectl delete -f - $ kustomize build k8s/environments | kubectl delete -f -
$ kustomize build k8s/stoage/nfs | kubectl delete -f - --wait $ kustomize build k8s/stoage/nfs | kubectl delete -f - --wait
``` ```
or 혹은
```sh ```sh
$ kubectl delete -k k8s/environments $ kubectl delete -k k8s/environments
$ kubectl delete -k k8s/stoage/nfs --wait $ kubectl delete -k k8s/stoage/nfs --wait
``` ```
The case of openstack is similar, so it is omitted. Openstack의 경우도 비슷하므로 생략합니다.

View File

@@ -0,0 +1,19 @@
apiVersion: v1
kind: PersistentVolume
metadata:
name: mysql-pv
labels:
env: production
tier: database
app: mysql
name: mysql-pv
spec:
capacity:
storage: 5Gi
accessModes:
- ReadWriteMany
storageClassName: nfs
persistentVolumeReclaimPolicy: Retain
nfs:
path: /srv/nfs
server: 192.168.56.21

View File

@@ -32,7 +32,7 @@ spec:
- "-c" - "-c"
- | - |
set -ex set -ex
[[ `hostname` =~ -([0-9]+)$ ]] || exit 1 [[ $HOSTNAME =~ -([0-9]+)$ ]] || exit 1
ordinal=${BASH_REMATCH[1]} ordinal=${BASH_REMATCH[1]}
echo [mysqld] > /mnt/conf.d/server-id.cnf echo [mysqld] > /mnt/conf.d/server-id.cnf
echo server-id=$((100 + $ordinal)) >> /mnt/conf.d/server-id.cnf echo server-id=$((100 + $ordinal)) >> /mnt/conf.d/server-id.cnf

View File

@@ -1,18 +0,0 @@
apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
name: jenkins-ingress
labels:
env: production
tier: cicd
app: jenkins
name: jenkins-ingress
spec:
rules:
- host: <젠킨스 도메인> # TODO
http:
paths:
- path: /
backend:
serviceName: jenkins
servicePort: 8080

View File

@@ -0,0 +1,20 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: jenkins-ingress
labels:
env: production
tier: cicd
app: jenkins
spec:
rules:
- host: <Jenkins 도메인> # TODO
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: jenkins
port:
number: 8080

View File

@@ -0,0 +1,4 @@
apiVersion: v1
kind: Namespace
metadata:
name: jenkins

View File

@@ -0,0 +1,19 @@
apiVersion: v1
kind: PersistentVolume
metadata:
name: jenkins-pv
labels:
env: production
tier: cicd
app: jenkins
name: jenkins-pv
spec:
capacity:
storage: 5Gi
accessModes:
- ReadWriteMany
storageClassName: nfs
persistentVolumeReclaimPolicy: Retain
nfs:
path: /srv/nfs
server: 192.168.56.21

View File

@@ -0,0 +1,15 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
namespace: jenkins
name: jenkins-role
rules:
- apiGroups: ["networking.k8s.io"]
resources: ["ingresses"]
verbs: ["get", "create", "update", "delete"]
- apiGroups: [""]
resources: ["services"]
verbs: ["get", "create", "update", "delete"]
- apiGroups: ["apps"]
resources: ["deployments"]
verbs: ["get", "create", "update", "delete", "patch"]

View File

@@ -0,0 +1,13 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
namespace: jenkins
name: jenkins-rolebinding
subjects:
- kind: ServiceAccount
name: jenkins
namespace: default
roleRef:
kind: Role
name: jenkins-role
apiGroup: rbac.authorization.k8s.io

View File

@@ -1,4 +1,4 @@
apiVersion: networking.k8s.io/v1beta1 apiVersion: networking.k8s.io/v1
kind: Ingress kind: Ingress
metadata: metadata:
name: kibana-ingress name: kibana-ingress
@@ -6,13 +6,15 @@ metadata:
env: production env: production
tier: logging tier: logging
app: kibana app: kibana
name: kibana-ingress
spec: spec:
rules: rules:
- host: <ELK Kibana 도메인> # TODO - host: <ELK Kibana 도메인> # TODO
http: http:
paths: paths:
- path: / - path: /
pathType: Prefix
backend: backend:
serviceName: kibana service:
servicePort: 5601 name: kibana
port:
number: 5601

View File

@@ -1,4 +1,4 @@
apiVersion: networking.k8s.io/v1beta1 apiVersion: networking.k8s.io/v1
kind: Ingress kind: Ingress
metadata: metadata:
name: rabbitmq-ingress name: rabbitmq-ingress
@@ -6,13 +6,15 @@ metadata:
env: production env: production
tier: backend tier: backend
app: rabbitmq app: rabbitmq
name: rabbitmq-ingress
spec: spec:
rules: rules:
- host: <RabbitMQ 도메인> # TODO - host: <RabbitMQ 도메인> # TODO
http: http:
paths: paths:
- path: / - path: /
pathType: Prefix
backend: backend:
serviceName: rabbitmq service:
servicePort: 15672 name: rabbitmq
port:
number: 15672

View File

@@ -1,4 +1,4 @@
apiVersion: extensions/v1beta1 apiVersion: networking.k8s.io/v1
kind: Ingress kind: Ingress
metadata: metadata:
name: zipkin-ingress name: zipkin-ingress
@@ -6,13 +6,16 @@ metadata:
env: production env: production
tier: backend tier: backend
app: zipkin app: zipkin
name: zipkin-ingress
spec: spec:
rules: rules:
- host: <Zipkin 도메인> # TODO - host: <Zipkin 도메인> # TODO
http: http:
paths: paths:
- path: / - path: /
pathType: Prefix
backend: backend:
serviceName: zipkin service:
servicePort: 9411 name: zipkin
port:
number: 9411