-
Notifications
You must be signed in to change notification settings - Fork 247
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
Delete userdata from VirtualBox/VMware after Ignition completes #1350
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Import vmware-archive/vmw-ovflib@53a0e9f7a4 verbatim; it's no longer maintained upstream. This is identical to the vendored vmw-ovflib code.
The license file is identical to the one in the root of the repo.
This was referenced Apr 20, 2022
jlebon
reviewed
Apr 27, 2022
bgilbert
added a commit
to coreos/fedora-coreos-config
that referenced
this pull request
Apr 27, 2022
Merged
We need to round-trip OVF environment XML, which uses XML namespace prefixes. encoding/xml can't handle those [1] and bad things happen if you try [2]. Use an external package instead. [1]: golang/go#9519 [2]: https://github.com/mattermost/xml-roundtrip-validator/blob/master/advisories/unstable-elements.md
For now, deleting Ignition configs from the provider will be handled by a separate program running in the real root. That allows a config with any spec version to disable the deletion by masking the unit.
Configs might be in guestinfo properties or OVF metadata. Remove any config in the OVF metadata, and replace any config in guestinfo (since we can't delete properties entirely).
Delete config and config-encoding guest properties.
Add a systemd service that runs ignition-rmcfg to delete userdata early in first boot on VirtualBox and VMware. This will fail the boot if it runs unsuccessfully, and can be masked in the config if desired. Add /usr/libexec/ignition-rmcfg as a symlink to the Ignition binary in the Dracut module, to save space. Distros will probably want to enable this service by default. Fixes #1315.
Addressed comments! |
jlebon
approved these changes
May 3, 2022
HuijingHei
pushed a commit
to HuijingHei/fedora-coreos-config
that referenced
this pull request
Oct 10, 2023
HuijingHei
pushed a commit
to HuijingHei/fedora-coreos-config
that referenced
this pull request
Oct 10, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Add an
ignition-rmcfg
multicall binary and corresponding service in the real root. On first boot in VirtualBox and VMware, run it to delete the Ignition config from the hypervisor. The service can be masked by the Ignition config if desired.Fixes #1315.