Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(build): add clouddriver-integration module to exercise the just-built docker imageTest docker image #6206

Merged
merged 6 commits into from
May 2, 2024

Conversation

dbyron-sf
Copy link
Contributor

Also, add a healthcheck to the docker images.

dbyron-sf added 5 commits May 1, 2024 14:50
with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.
to facilitate testing container startup
multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59
@@ -64,5 +65,5 @@ COPY clouddriver-web/build/install/clouddriver /opt/clouddriver
RUN mkdir -p /opt/clouddriver/plugins && chown -R spinnaker:nogroup /opt/clouddriver/plugins

USER spinnaker

HEALTHCHECK CMD curl http://localhost:7002/health | grep UP || exit 1
Copy link
Contributor

@xibz xibz May 1, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, this wouldn't work right? Because it's a complete object.

{"status":"DOWN","components":{"clientConfigServer":{"status":"UNKNOWN","details":{"error":"no property sources located"}},"configServer":{"status":"UP","details":{"repositories":[{"name":"app","profiles":["default"],"label":null}]}},"db":{"status":"UP","details":{"database":"POSTGRES"}},"discoveryComposite":{"description":"Discovery Client not initialized","status":"UNKNOWN","components":{"discoveryClient":{"description":"Discovery Client not initialized","status":"UNKNOWN"}}},"diskSpace":{"status":"UP","details":{"total":1000240963584,"free":361212166144,"threshold":10485760,"exists":true}},"dockerRegistry":{"status":"UP"},"kubernetes":{"status":"UP"},"ping":{"status":"UP"},"reactiveDiscoveryClients":{"description":"Discovery Client not initialized","status":"UNKNOWN","components":{"Simple Reactive Discovery Client":{"description":"Discovery Client not initialized","status":"UNKNOWN"}}},"redisHealth":{"status":"UP","details":{"maxIdle":100,"minIdle":25,"numActive":0,"numIdle":3,"numWaiters":0}},"refreshScope":{"status":"DOWN"}}}

We need to check if the root status is UP and not a wide search, otherwise it could be a false positive.

We could instead install jq if it doesn't already exist, and just query for it directly with jq '.status'

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MOST of the time it's only a complete object IF the "management" exposes ALL data. USUALLY it's a single line check.

Copy link
Contributor

@xibz xibz May 1, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Understood, but better safe to assume that things may be configured differently or be subject to change, than having a pleasant surprise :p

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

{"status":"DOWN"}

AKA this data is NORMALLY what's returned unless you use:

       management:
          endpoints.web:
            exposure.include: "*"

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(or similar)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BUT... jq adds more deps... and this isn't used in k8s - only in say testiing via docker CLI. I'm not AGAINST JQ - particularly since can be useful... just a "which is the less evil"

Copy link
Contributor

@xibz xibz May 1, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a small dep for preventing false positives. So I'd argue that is probably more satisfactory. We could also use something like perl, awk, etc to achieve this if those are included in our slim image, but the command is going to be much more unreadable if dependencies are that much of a concern. If we build our docker images intelligently, it should not be too bad to add a single binary.

Copy link
Contributor

@xibz xibz May 1, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And we are already adding curl in this PR, so adding jq doesn't seem to be that bad since curl isn't used in k8s either

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How's ad6cf9a ?

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.
Copy link
Contributor

@xibz xibz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved! I left a comment, but it seemed to have vanished lol. But good approach! Forgot about --fail and no extra deps!

@dbyron-sf dbyron-sf added the ready to merge Approved and ready for a merge label May 2, 2024
@mergify mergify bot added the auto merged Merged automatically by a bot label May 2, 2024
@mergify mergify bot merged commit 9ea2224 into spinnaker:master May 2, 2024
23 checks passed
@dbyron-sf dbyron-sf deleted the test-docker-image branch May 2, 2024 04:25
@dbyron-sf dbyron-sf changed the title feat(build): add fiat-integration module to exercise the just-built docker imageTest docker image feat(build): add clouddriver-integration module to exercise the just-built docker imageTest docker image May 2, 2024
@dbyron-sf
Copy link
Contributor Author

Let's see if mergify will let me backport this even though it's marked as a feature....There's a bug migrating from release 1.32.x to the current (5-jun-24) HEAD of master when running postgres, and there's a way to demonstrate this with an extension of these tests...but to do that we need a docker image with a HEALTHCHECK in the release-1.32.x branch...

@dbyron-sf
Copy link
Contributor Author

@Mergifyio backport release-1.32.x

Copy link
Contributor

mergify bot commented Jun 5, 2024

backport release-1.32.x

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Jun 5, 2024
…ocker imageTest docker image (#6206)

* fix(web): replace deprecated spring.profiles in configuration

with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.

* feat(docker): add HEALTHCHECK

to facilitate testing container startup

* feat(build): add clouddriver-integration module to exercise the just-built docker image

* feat(gha): run integration test in pr builds

multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59

* feat(gha): run integration test in branch builds

* fix(docker): reduce the chance for false positives in the health check

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.

(cherry picked from commit 9ea2224)

# Conflicts:
#	.github/workflows/pr.yml
#	Dockerfile.java11.slim
#	Dockerfile.java11.ubuntu
#	Dockerfile.ubuntu
dbyron-sf added a commit that referenced this pull request Jun 5, 2024
…ocker imageTest docker image (#6206)

* fix(web): replace deprecated spring.profiles in configuration

with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.

* feat(docker): add HEALTHCHECK

to facilitate testing container startup

* feat(build): add clouddriver-integration module to exercise the just-built docker image

* feat(gha): run integration test in pr builds

multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59

* feat(gha): run integration test in branch builds

* fix(docker): reduce the chance for false positives in the health check

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.

(cherry picked from commit 9ea2224)

The release-1.32.x branch only has Dockerfile.slim and Dockerfile.ubuntnu, so removing the java11 Dockerfiles.  The conflict in Dockerfile.ubuntu was about java 11 vs java 17.
mergify bot added a commit that referenced this pull request Jun 5, 2024
…built docker imageTest docker image (backport #6206) (#6222)

* feat(build): add fiat-integration module to exercise the just-built docker imageTest docker image (#6206)

* fix(web): replace deprecated spring.profiles in configuration

with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.

* feat(docker): add HEALTHCHECK

to facilitate testing container startup

* feat(build): add clouddriver-integration module to exercise the just-built docker image

* feat(gha): run integration test in pr builds

multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59

* feat(gha): run integration test in branch builds

* fix(docker): reduce the chance for false positives in the health check

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.

(cherry picked from commit 9ea2224)

The release-1.32.x branch only has Dockerfile.slim and Dockerfile.ubuntnu, so removing the java11 Dockerfiles.  The conflict in Dockerfile.ubuntu was about java 11 vs java 17.

* fix(integration): add org.junit.jupiter:junit-jupiter-engine dependency

so the tests actually run

---------

Co-authored-by: David Byron <[email protected]>
Co-authored-by: David Byron <[email protected]>
@dbyron-sf
Copy link
Contributor Author

And similarly, let's backport to 1.33.x and 1.34.x so we can verify fixes there too.

@dbyron-sf
Copy link
Contributor Author

@Mergifyio backport release-1.33.x release-1.34.x

Copy link
Contributor

mergify bot commented Jun 11, 2024

backport release-1.33.x release-1.34.x

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Jun 11, 2024
…ocker imageTest docker image (#6206)

* fix(web): replace deprecated spring.profiles in configuration

with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.

* feat(docker): add HEALTHCHECK

to facilitate testing container startup

* feat(build): add clouddriver-integration module to exercise the just-built docker image

* feat(gha): run integration test in pr builds

multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59

* feat(gha): run integration test in branch builds

* fix(docker): reduce the chance for false positives in the health check

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.

(cherry picked from commit 9ea2224)
mergify bot pushed a commit that referenced this pull request Jun 11, 2024
…ocker imageTest docker image (#6206)

* fix(web): replace deprecated spring.profiles in configuration

with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.

* feat(docker): add HEALTHCHECK

to facilitate testing container startup

* feat(build): add clouddriver-integration module to exercise the just-built docker image

* feat(gha): run integration test in pr builds

multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59

* feat(gha): run integration test in branch builds

* fix(docker): reduce the chance for false positives in the health check

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.

(cherry picked from commit 9ea2224)
mergify bot added a commit that referenced this pull request Jun 11, 2024
…ocker imageTest docker image (#6206) (#6228)

* fix(web): replace deprecated spring.profiles in configuration

with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.

* feat(docker): add HEALTHCHECK

to facilitate testing container startup

* feat(build): add clouddriver-integration module to exercise the just-built docker image

* feat(gha): run integration test in pr builds

multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59

* feat(gha): run integration test in branch builds

* fix(docker): reduce the chance for false positives in the health check

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.

(cherry picked from commit 9ea2224)

Co-authored-by: David Byron <[email protected]>
mergify bot added a commit that referenced this pull request Jun 11, 2024
…ocker imageTest docker image (#6206) (#6227)

* fix(web): replace deprecated spring.profiles in configuration

with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.

* feat(docker): add HEALTHCHECK

to facilitate testing container startup

* feat(build): add clouddriver-integration module to exercise the just-built docker image

* feat(gha): run integration test in pr builds

multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59

* feat(gha): run integration test in branch builds

* fix(docker): reduce the chance for false positives in the health check

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.

(cherry picked from commit 9ea2224)

Co-authored-by: David Byron <[email protected]>
aman-agrawal pushed a commit to aman-agrawal/clouddriver that referenced this pull request Jul 5, 2024
…ocker imageTest docker image (spinnaker#6206) (spinnaker#6227)

* fix(web): replace deprecated spring.profiles in configuration

with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.

* feat(docker): add HEALTHCHECK

to facilitate testing container startup

* feat(build): add clouddriver-integration module to exercise the just-built docker image

* feat(gha): run integration test in pr builds

multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59

* feat(gha): run integration test in branch builds

* fix(docker): reduce the chance for false positives in the health check

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.

(cherry picked from commit 9ea2224)

Co-authored-by: David Byron <[email protected]>
aman-agrawal pushed a commit to OpsMx/clouddriver-oes that referenced this pull request Jul 8, 2024
…ocker imageTest docker image (spinnaker#6206) (spinnaker#6227)

* fix(web): replace deprecated spring.profiles in configuration

with spring.config.activate.on-profile to remove these warnings:

2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 375:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 363:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 350:13]
2024-05-01 21:29:23.746  WARN 1 --- [           main] o.s.b.c.config.ConfigDataEnvironment     : Property 'spring.profiles' imported from location 'class path resource [clouddriver.yml]' is invalid and should be replaced with 'spring.config.activate.on-profile' [origin: class path resource [clouddriver.yml] - 312:13]

See https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-Config-Data-Migration-Guide#profile-specific-documents.

* feat(docker): add HEALTHCHECK

to facilitate testing container startup

* feat(build): add clouddriver-integration module to exercise the just-built docker image

* feat(gha): run integration test in pr builds

multi-arch with --load doesn't work, so add a separate step using the local platform to
make an image available for testing.

see docker/buildx#59

* feat(gha): run integration test in branch builds

* fix(docker): reduce the chance for false positives in the health check

In case the health check contains more detailed information where one check could report UP but the overall status is down/out of service/etc.

See https://docs.spring.io/spring-boot/docs/2.6.15/reference/html/actuator.html#actuator.endpoints.health for more.

(cherry picked from commit 9ea2224)

Co-authored-by: David Byron <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto merged Merged automatically by a bot ready to merge Approved and ready for a merge target-release/1.35
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants