Skip to content

feat: package generation ALPHA - #2269

Merged
Noxsios merged 61 commits into
mainfrom
821-package-generation
Mar 13, 2024
Merged

Noxsios merged 61 commits into
mainfrom
821-package-generation

Conversation

@andrewg-xyz

@andrewg-xyz andrewg-xyz commented Jan 30, 2024 •

Copy link
Copy Markdown
Contributor

Description

Introduce Zarf package generation from a source

Related Issue

Fixes #821

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Other (security config, docs update, etc)

Checklist before merging

@netlify

netlify Bot commented Jan 30, 2024 •

Copy link
Copy Markdown

✅ Deploy Preview for zarf-docs canceled.

Name Link
🔨 Latest commit c2d07d0
🔍 Latest deploy log https://app.netlify.com/sites/zarf-docs/deploys/65f1a807690aa20008adc30f

@andrewg-xyz
andrewg-xyz marked this pull request as draft January 30, 2024 03:32
@andrewg-xyz

Copy link
Copy Markdown
Contributor Author

I was able to smoke test function pre and post rebase via:

mkdir tmp-gen && cd tmp-gen
helm pull oci://ghcr.io/stefanprodan/charts/podinfo && tar -xf podinfo-6.5.4.tgz
../build/zarf-mac-apple package generate my-podinfo --from ./podinfo

Both produced zarf.yaml

kind: ZarfPackageConfig
metadata:
  name: my-podinfo
components:
- name: component-local-chart-podinfo-87f03f37-b831-4968-8b5b-acf0a54530b6
  charts:
  - name: podinfo
    version: 6.5.4
    localPath: ./podinfo
    namespace: zarf-generated-local-chart-podinfo

@andrewg-xyz

Copy link
Copy Markdown
Contributor Author

a few things to chase down/confirm:

  • ZarfCreateOptions.{CachePath,Insecure} moved to ZarfCommonOptions.{CachePath,Insecure}
  • ZarfCreateOptions.OutputDirectory >> move to? maybe ZarfPullOptions.OutputDirectory
  • a few merge conflicts were due to functionality partially ported to pkg, need to confirm no more internal functionality exists that has been moved

a few things I know can be improved:

  • switch blocks in package Generate command
  • check implementation for new package structure in zarf

@andrewg-xyz
andrewg-xyz force-pushed the 821-package-generation branch from 28393f0 to eda795e Compare February 9, 2024 20:05
@Noxsios Noxsios changed the title feat: package generation (#821) feat: package generation Feb 23, 2024
@andrewg-xyz
andrewg-xyz force-pushed the 821-package-generation branch 2 times, most recently from 1ea909d to bf8b450 Compare February 26, 2024 23:22
Comment thread src/pkg/packager/prepare.go Resolved
Comment thread src/cmd/dev.go Resolved
Comment thread src/config/config.go Resolved
Comment thread src/cmd/dev.go Resolved
Comment thread src/pkg/packager/generate.go Resolved
Comment thread src/pkg/packager/generate.go Resolved
Comment thread src/config/config.go Resolved
Comment thread src/pkg/packager/generate.go Resolved
Comment thread src/pkg/packager/prepare.go Resolved
Comment thread src/types/runtime.go Resolved
Comment thread src/config/lang/english.go Resolved
AustinAbro321
AustinAbro321 previously approved these changes Mar 1, 2024
@AustinAbro321

Copy link
Copy Markdown
Member

LGTM, we will need approval from someone else on the zarf team

@Racer159 Racer159 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Adding comments, mostly cleaning up string building, but there are a few things that could make this more generally useful and one issue with garbled text.

Comment thread src/cmd/dev.go Resolved
Comment thread src/pkg/packager/generate.go Resolved
Comment thread src/cmd/dev.go Resolved
Comment thread src/pkg/packager/generate.go Resolved
Comment thread src/pkg/packager/generate.go Resolved
Comment thread src/pkg/packager/generate.go Resolved
andrewg-xyz and others added 7 commits March 7, 2024 21:16
Signed-off-by: razzle <harry@razzle.cloud>
Signed-off-by: razzle <harry@razzle.cloud>
Signed-off-by: razzle <harry@razzle.cloud>
Signed-off-by: razzle <harry@razzle.cloud>
Signed-off-by: razzle <harry@razzle.cloud>
@Noxsios Noxsios changed the title feat: package generation feat: package generation **ALPHA** Mar 13, 2024
@Noxsios Noxsios changed the title feat: package generation **ALPHA** feat: package generation ALPHA Mar 13, 2024
@Noxsios
Noxsios merged commit 9608731 into main Mar 13, 2024
@Noxsios
Noxsios deleted the 821-package-generation branch March 13, 2024 14:17
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.

Package Generation for projects

6 participants