diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index cdeacb4..0d62301 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -1,4 +1,4 @@ -name: Config server CI with gradle +name: Eureka server CI with gradle on: push: @@ -20,13 +20,6 @@ jobs: java-version: '17' distribution: 'temurin' - - name: Set Yaml - uses: microsoft/variable-substitution@v1 - with: - files: ./src/main/resources/application.yml - env: - spring.config.import: ${{ secrets.CONFIG_SERVER_URL }} - - name: Grant execute permission for gradlew run: chmod +x gradlew @@ -69,13 +62,13 @@ jobs: id: check-container run: | if sudo docker ps -a | grep -q eureka-server; then - echo "running=true" >> $GITHUB_OUTPUT + echo "eureka-server-running=true" >> $GITHUB_OUTPUT else - echo "running=false" >> $GITHUB_OUTPUT + echo "eureka-server-running=false" >> $GITHUB_OUTPUT fi - name: Stop and remove container - if: steps.check-container.outputs.running == 'true' + if: steps.check-container.outputs.eureka-server-running == 'true' run: sudo docker stop eureka-server - name: Run new docker container diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml index 1dbf4f5..865ef09 100644 --- a/src/main/resources/application.yml +++ b/src/main/resources/application.yml @@ -2,7 +2,7 @@ spring: application: name: eureka-server config: - import: ${config-server} + import: optional:configserver:http://43.203.131.185:8071 cloud: loadbalancer: enabled: true \ No newline at end of file