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

Ability to use package variables within a uds-bundle #370

Closed
brianrexrode opened this issue Jan 30, 2024 · 0 comments
Closed

Ability to use package variables within a uds-bundle #370

brianrexrode opened this issue Jan 30, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@brianrexrode
Copy link

Is your feature request related to a problem? Please describe

It would nice to be able to pass variables from one zarf package to another within a uds-bundle whether they are expected ZARF_VARs or not.

A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
I would like to use uds-core packages within my AWS EKS environments and configure components like loki to use AWS resources. The resources would need to be created prior to deploying uds-core and in most cases require outputs to be used as values inputs to the helm charts. What if the uds-core loki values do not expose ZARF_VARs needed to properly configure my deployment on AWS?

Ex.
I've created a zarf package that deploys S3 buckets, creates associated IRSA roles and policies, as well as defines the AWS Region I'm deploying to. Those outputs need to be passed along to the uds-core loki component's helm values. Each AWS environment I deploy to will/may have different values for each resource.

I can export these ZARF_VARs from my custom s3-irsa-iac zarf package within my uds-bundle and import them to the uds-core package but it's my understanding they are useless if the uds-core package is not expecting the same ZARF_VARs

    exports:
      - name: LOKI_S3_BUCKET
      - name: LOKI_S3_IRSA_ROLE_ARN
      - name: LOKI_S3_AWS_REGION

    imports:
      - name: LOKI_S3_BUCKET
        package: s3-irsa-iac
      - name: LOKI_S3_IRSA_ROLE_ARN
        package: s3-irsa-iac
      - name: LOKI_S3_AWS_REGION
        package: s3-irsa-iac

I

Describe the solution you'd like

It would be nice to have the ability to use those exported ZARF_VARs within the uds-bundle as regular VARs.
Ex.

      overrides:
          loki:
          values:
            - path: objectStorage.endpoint
              value: https://s3.amazonaws.com
          variables:
            - path: objectStorage.region
              value: ${LOKI_S3_AWS_REGION}
            - path: objectStorage.bucketName
              value: ${LOKI_S3_BUCKET}
  • Given a state
  • When an action is taken
  • Then something happens

Describe alternatives you've considered

Hardcoding the values I'm trying to override
(optional) A clear and concise description of any alternative solutions or features you've considered.

Additional context

Add any other context or screenshots about the feature request here.

@brianrexrode brianrexrode added the enhancement New feature or request label Jan 30, 2024
@decleaver decleaver self-assigned this Feb 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants