> For the complete documentation index, see [llms.txt](https://wannaqueen.gitbook.io/spring5/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://wannaqueen.gitbook.io/spring5/spring-boot/undefined-1/25.-by-ks-1/25.2.md).

# 25.2 프로그램적으로 프로파일 세팅

&#x20;`SpringApplication.setAdditionalProfiles(…​)`응용 프로그램을 실행하기 전에 호출 하여 활성 프로파일을 프로그래밍 방식으로 설정할 수 있습니다 . Spring의 `ConfigurableEnvironment`인터페이스 를 사용하여 프로필을 활성화 할 수도 있습니다 .

{% hint style="info" %}
**setAdditionalProfiles**

```
public void setAdditionalProfiles(String... profiles)
```

Set additional profile values to use (on top of those set in system or command line properties).Parameters:`profiles` - the additional profiles to set

참조 : API 문서

인자를 위의 예제로 치면 dev를 입력하면 되는 듯
{% endhint %}
