Skip to content

feat: render global environment outside tutor-env#5

Merged
mariajgrimaldi merged 1 commit into
mainfrom
MJG/global-stack
Aug 10, 2022
Merged

feat: render global environment outside tutor-env#5
mariajgrimaldi merged 1 commit into
mainfrom
MJG/global-stack

Conversation

@mariajgrimaldi
Copy link
Copy Markdown
Contributor

@mariajgrimaldi mariajgrimaldi commented Aug 2, 2022

Description

This PR adds a new manifest builder that generates manifests outside the usual tutor environment, which are meant to be used to create global resources for a cluster.

How to test

Generate a drydock environment using a reference with the GlobalManifests builder, e.g:

drydock:
  builder_class:  drydock.manifest_builder.application.manifest_builder.ManifestBuilder
  config_class: drydock.manifest_builder.infrastructure.tutor_config.TutorExtendedConfig
  manifest_class: drydock.manifest_builder.infrastructure.tutor_based_manifests.GlobalManifests
  manifest_options:
    output: "global-env"

After running tutor drydock save -r drydock-reference.yml, a new env called global-env will be generated with the customization file rendered

Comment thread drydock/manifest_builder/infrastructure/tutor_based_manifests.py
Comment thread drydock/templates/kustomized/global-stack/kustomization.yml
Comment thread drydock/templates/kustomized/global-stack/kustomization.yml Outdated
@mariajgrimaldi mariajgrimaldi marked this pull request as ready for review August 3, 2022 13:33
Comment thread drydock/templates/kustomized/global-stack/kustomization.yml Outdated
@mariajgrimaldi mariajgrimaldi force-pushed the MJG/global-stack branch 2 times, most recently from 090ff42 to ad5c31e Compare August 3, 2022 17:36
version: {{ DRYDOCK_PROMETHEUS_VERSION }}
releaseName: prometheus
includeCRDs: true
{%- if DRYDOCK_PROMETHEUS_VALUES | default(false) %}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I'm thinking of not using default here and instead having them in the defaults.yml file? That way we can refer to that file to know what variables are available.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Done! :)

Comment thread drydock/templates/kustomized/tutor13/defaults.yml
Comment thread drydock/templates/kustomized/global-stack/kustomization.yml Outdated
@mariajgrimaldi
Copy link
Copy Markdown
Contributor Author

hey! what do you think now? @jfavellar90 @MoisesGSalas

Comment thread drydock/templates/kustomized/global-stack/defaults.yml Outdated
Comment thread drydock/templates/kustomized/global-stack/kustomization.yml Outdated
@mariajgrimaldi mariajgrimaldi merged commit f114243 into main Aug 10, 2022
@MoisesGSalas MoisesGSalas deleted the MJG/global-stack branch November 16, 2023 15:18
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.

3 participants