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

jx-requirements.yml.tpl doesn't reflect changes for storage key in Jenkins X v3 #232

Open
polasekr opened this issue Jan 18, 2021 · 1 comment

Comments

@polasekr
Copy link

Summary

Storage key in the template is object, while Jenkins X v3 requires it to be an array. When jx-requirement.yml file generated by the template while storage is enabled, following jx-requirement.yml file is rendered

  logs:
    enabled: true
    url: s3://s3bucket
  reports:
    enabled: true
    url: s3://s3bucket
  repository:
    enabled: true
    url: s3://s3bucket

Jenkins X throws following error:

Error: failed to load requirements in dir .: failed to unmarshal YAML file /home/robert/src/stjude/jx3-config/jx-requirements.yml due to error unmarshaling JSON: while decoding JSON: json: cannot unmarshal object into Go struct field RequirementsConfig.spec.storage of type []v4beta1.StorageConfig

Steps to reproduce the behavior

Build jenkins x v3 with storage enabled

Expected behavior

jx-requirement.yml suppose to be in the following format:

...
  storage:
  - name: logs
    url: gs://logs-tf-jx-gentle-titmouse-1603d78dd9a2
  - name: reports
    url: gs://reports-tf-jx-gentle-titmouse-1603d78dd9a2
  - name: repository
    url: gs://repository-tf-jx-gentle-titmouse-1603d78dd9a2

as per https://github.com/jenkins-x/jx3-eagle/blob/master/jx-requirements.yml

Actual behavior

Terraform version

n/a
The output of terraform version is:

n/a

Module version

n/a

Operating system

n/a

@ankitm123
Copy link
Member

ankitm123 commented Jan 19, 2021

https://github.com/jenkins-x/terraform-google-jx/blob/master/modules/jx-requirements.yml.tpl#L38 -> Even the google module has the same values afaict. The requirement file should change during the jx gitops merge step.

Are u using the beta version or alpha version of jx?

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

No branches or pull requests

2 participants