-
Notifications
You must be signed in to change notification settings - Fork 17
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
translate: support deprecated create
filesystem object
#28
Open
tormath1
wants to merge
4
commits into
coreos:main
Choose a base branch
from
tormath1:tormath1/support-create
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+1,049
−223
Open
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
9269ac6
translate: prevent `mount.create` from being unforced
tormath1 a7edb84
translate: translate `create` deprecated option
tormath1 520bfdb
translate_test: add test for deprecated `create` object
tormath1 058ae48
test: deprecated config 2_4 with create.force to false
tormath1 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If
Force
is true, it's safe to setWipeFilesystem
true. But ifMount.Create
is non-nil andForce
is false, I think we should fail the translation. In that situation, the config is asking for the FS to be created if it doesn't exist, and for Ignition to fail otherwise. For the case where the filesystem exists and matches the specified parameters (format etc.), Ignition 2.x can't deliver those semantics: provisioning would succeed instead.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I get your point - and this is something I'd like to talk with you; maybe in a dedicated issue. Currently
ign-converter
expects afsMap
to map file systems with path, what if we could generate this value on the fly, with something like:There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's discuss that change in a separate issue. I don't think it's relevant here, though? The problem here isn't the mountpoint, but what to do if the specified
Device
already has a filesystem superblock on it.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, the issue is created in here: #30
Got it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, cool. So let's add an error return in
Check2_*
iff.Mount.Create != nil && !f.Mount.Create.Force
, and a comment here referring to that.