SpringBoot is a framework. How it handles this is different from every other 
framework.

Easiest way in Go, just name your configuration files similar to 
filename.mode.yaml where mode is prod, dev, qa, etc. and set a env variable for 
the mode.

You can then take it from there, and have base configurations, etc.

All that being said, you might look at a Go configuration library like viper 
<https://github.com/spf13/viper> and there are many more...

> On May 17, 2020, at 2:15 PM, Volker Dobler <dr.volker.dob...@gmail.com> wrote:
> 
> Go, the language and the std tooling has no predefined
> way of doing this. Do whatever fits your need.
> 
> V.
> 
> On Sunday, 17 May 2020 19:19:23 UTC+2, Shishira Pradhan wrote:
> Hi All,
> 
> i'm a java developer, currently working on golang. In springboot, we have 
> configuration like port, database etc info are stored in yaml files like 
> application-dev.yml,   application-test.yml, application-prod.yml profiles, 
> and profile name is passed during running the application to load profile 
> specific configuration. I need to understand that how to load/pass profile 
> based properties in golang ?
> 
> Thanks,
> shishira
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "golang-nuts" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to golang-nuts+unsubscr...@googlegroups.com 
> <mailto:golang-nuts+unsubscr...@googlegroups.com>.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/golang-nuts/8c3072ff-0848-455a-854c-c8f515792dc0%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/golang-nuts/8c3072ff-0848-455a-854c-c8f515792dc0%40googlegroups.com?utm_medium=email&utm_source=footer>.

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/CF692C5E-B44B-4676-8ECA-7413A4D54DD8%40ix.netcom.com.

Reply via email to