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

CLIP-1878: Update KinD scripts and config to be able to run DC functional tests #812

Merged
merged 3 commits into from
Jun 4, 2024

Conversation

bianchi2
Copy link
Collaborator

@bianchi2 bianchi2 commented Jun 1, 2024

There's a handful of smallish changes to existing KinD scripts and configuration files to make them more flexible. Changes include:

  • bump KinD and K8S version, make it possible to pass overrides or use default versions
  • deploy an insecure container registry and map its NodePort on host port 5001 (not used at the moment but we may have scenarios where we need to build a local image and push it to the container registry)
  • update Postgres deployment function, use the latest Helm chart version, optionally init database if the path to init file is passed
  • make deploy script runnable on local Mac, use tmp locations for config files (to run sed against), avoid cd to directories, modify sed command when on Mac
  • introduce MICS_OVERRIDES env var in which you can pass whatever --set you need
  • group --set overrides to avoid duplication of --set
  • optionally create hostPath PV and PVC (nfs server can't run on arm64 machines, so instead of nfs PV a hostPath PV is used)
  • create backdoor NodePort services for the deployed DC app (with sts replica name as label selector and predefined NodePort which is mapped to a host port - 81 and 82)
  • add additional env vars and sys props to common config to make deployed products ready for functional testing (disable welcome screen, enable insecure login etc)
  • add comments to common config and deploy script to explain why we need extra values and what functions are doing

--wait
# this is for local runs, because existing nfs server images does not run on arm64 platforms
# instead, we create a hostPath RWX volume and override the default common settings
if [ -z "${HOSTPATH_PV}" ]; then
Copy link
Collaborator

Choose a reason for hiding this comment

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

Where is this HOSTPATH_PV set? Do we set it when we want to run the test in our local arm64 machine?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yes, that;s when we want to use it.

storage: 1Gi
selector:
matchLabels:
app: hostpath-shared-home
Copy link
Collaborator

Choose a reason for hiding this comment

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

Where is this label being set?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

That's leftovers from a lot of local debugging. Removed.

@bianchi2 bianchi2 merged commit 857ba11 into main Jun 4, 2024
3 checks passed
@bianchi2 bianchi2 deleted the CLIP-1878-migration-to-kind branch June 4, 2024 03:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants