We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fd94ff9 commit 84d17b4Copy full SHA for 84d17b4
src/main/java/com/back/global/initData/DevInitData.java
@@ -22,6 +22,7 @@
22
import java.util.List;
23
24
@Configuration
25
+@Profile("default")
26
@RequiredArgsConstructor
27
public class DevInitData {
28
private final UserRepository userRepository;
@@ -34,13 +35,6 @@ public class DevInitData {
34
35
@Bean
36
ApplicationRunner DevInitDataApplicationRunner() {
37
return args -> {
- String activeProfile = environment.getProperty("spring.profiles.active", "none");
38
- if (!"default".equals(activeProfile)) {
39
- return; // default 환경이 아니면 실행하지 않음
40
- }
41
-// if (!"none".equals(activeProfile) && !"default".equals(activeProfile)) {
42
-// return;
43
-// }
44
initUsersAndPostsAndComments();
45
};
46
}
0 commit comments