Extend the Flatcar Container Linux installer script to include a -D option for local image download#37
Extend the Flatcar Container Linux installer script to include a -D option for local image download#37pothos merged 1 commit intoflatcar:flatcar-masterfrom jasonbraganza:mjb-adapt-init-2
Conversation
|
@marga-kinvolk, @pothos thank you both. will work on all you’ve said. |
|
working on all of this. almost done. will update once i am done testing. |
|
@marga-kinvolk @pothos - done. would be grateful for further advice or action. |
margamanterola
left a comment
There was a problem hiding this comment.
Thanks, this looks much better. Just one comment about the command documentation and two nits (this is small comments that are not very important).
Once you've solved this, would you please squash your commits into just one and make sure that the commit description has the right information? Thanks.
The -D flag will download Flatcar Container Linux image to the current directory, without installing it Signed-off-by: Mario Jason Braganza <jason@janusworx.com>
|
Te squash and commit are done. |
pothos
left a comment
There was a problem hiding this comment.
Gave it another test run and it works good, thanks!
A minor thing is that umask 077 makes the downloaded file restricted to the downloading user which could be reverted afterwards (but not skipped because it's maybe relevant for the verification keys in /tmp)
|
what would you suggest the mask be, @pothos? i could try working on that aspect too |
|
I think it's out of scope, but I would say before running |
|
@pothos just so i understand correctly, you want the downloaded file to have 755 permissions so the download ought to run with a 022 mask and then set back to 077? as for scope, well, i want to learn and do, so no worries there :) |
|
I meant we can first merge the PR as is if you want :) Yes, the umask is done to limit the temporary gpg folder I think and it's good to keep it, but I would just reset the umask to the previous value before the download starts. This way the user can still control the final permissions by tweaking umask before starting the download script. |
|
@pothos aah that sounds a teensy bit involved, so yes, i’ll wait for the pr to be merged and do this as a separate pr, if it’s ok with you folks :) |
|
Yes, thanks again |
Here again the suggestion in a better format: |

Title: Added flag to flatcar-install to only download the image file, as required by issue #248
The
install_from_urlscript was refactored.We now have 3 functions
prep_urlhandles setting of variables and gpg keys for the downloadinstall_from_urldoes the original task of downloading and writing to a diskdownload_from_urldownloads the bz2 image to the current folder and saves it.Closes flatcar/Flatcar#248
How to use
run
flatcar-install -Dand the script should download the image to the current folderTesting done
Have tried downloading the image across two computers.
Has successfully executed on one.
Still downloading on the other (results expected)