Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Spring with spring.config.location

I am trying to point at path to external configuration file like this:

--spring.config.location=file: C:/Users/some_user/workspace/repository1/payment-api/payment.yml

and it doesn't work. Any idea why?

like image 425
user3528733 Avatar asked Apr 16 '26 15:04

user3528733


1 Answers

The proper prefix is file://. On Windows you need an extra "/" in the file URL if it is absolute with a drive prefix

Try file:///C:/Users/some_user/workspace/repository1/payment-api/payment.yml instead.

like image 92
Stephane Nicoll Avatar answered Apr 19 '26 14:04

Stephane Nicoll



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!