Sage-Bionetworks / sage-monorepo

Where OpenChallenges, Schematic, and other Sage open source apps are built
https://sage-bionetworks.github.io/sage-monorepo/
Apache License 2.0
21 stars 12 forks source link

refactor(openchallenges): overideable config-server spring import config #2722

Closed zaro0508 closed 6 days ago

zaro0508 commented 6 days ago

spring boot issue 3346 says it's not possible to override Spring Import with SPRING_CONFIG_IMPORT env var. The suggestion is to use confighost instead which can be overriden with a CONFIGHOST env var.

tschaffter commented 6 days ago

Solution

Before

spring:
  config:
    import: 'configserver:http://openchallenges-config-server:8090'

After

spring:
  config:
    import: 'configserver:'
  cloud:
    config:
      uri: http://openchallenges-config-server:8090

The value of spring.cloud.config.uri can be overridden with the environment variable SPRING_CLOUD_CONFIG_URI

Notes

sonarcloud[bot] commented 6 days ago

Quality Gate Passed Quality Gate passed for 'openchallenges-challenge-service'

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud

sonarcloud[bot] commented 6 days ago

Quality Gate Passed Quality Gate passed for 'openchallenges-image-service'

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud

sonarcloud[bot] commented 6 days ago

Quality Gate Passed Quality Gate passed for 'openchallenges-organization-service'

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud