Move root partition resizing logic to VM.grow_root_partition() - #542
Conversation
757ef63 to
eef0398
Compare
58bac05 to
e5d048c
Compare
ydirson
left a comment
There was a problem hiding this comment.
It would be good to add more context, not everyone is expected to know what this partition resizing is about
| # growpart is not available in alpine 3.12 | ||
| # vm.ssh('apk add cloud-utils-growpart e2fsprogs-extra') | ||
| self.ssh('apk add gawk util-linux e2fsprogs-extra') | ||
| self.ssh( | ||
| 'wget https://raw.githubusercontent.com/canonical/cloud-utils/main/bin/growpart -O /usr/bin/growpart' | ||
| ) | ||
| self.ssh('chmod +x /usr/bin/growpart') |
There was a problem hiding this comment.
This still gives an external dependency on known-flaky github, I'm not sure we want to have more of them.
Is there any particular reason to use such an external tool? Wouldn't parted just avoid this?
There was a problem hiding this comment.
It doesn't add a dependency, it's already there.
There was a problem hiding this comment.
I removed growpart and used sfdisk and partx instead, which were already dependencies
eef0398 to
2b44b30
Compare
e5d048c to
2dfde42
Compare
2b44b30 to
c643b60
Compare
a6d89bc to
bd9fc0e
Compare
c643b60 to
6738a0e
Compare
bd9fc0e to
227d3fc
Compare
6738a0e to
0b91aaa
Compare
227d3fc to
23beb66
Compare
022f4bf to
a10e49e
Compare
13c905d to
96153b6
Compare
a10e49e to
972c6af
Compare
30750b4 to
d87c336
Compare
Millefeuille42
left a comment
There was a problem hiding this comment.
The two of my remaining comments aren't blocking, but must be resolved either way (applying the suggestion or not) before merging.
And make it a bit more robust, by: - fetching the actual partition mounted on / - checking if the filesystem is ext* Signed-off-by: Gaëtan Lehmann <gaetan.lehmann@vates.tech>
github is not exactly reliable these days. use sfdisk, which is also used by growpart internally Signed-off-by: Gaëtan Lehmann <gaetan.lehmann@vates.tech>
Signed-off-by: Gaëtan Lehmann <gaetan.lehmann@vates.tech>
Signed-off-by: Gaëtan Lehmann <gaetan.lehmann@vates.tech>
and implement missing command for opensuse Signed-off-by: Gaëtan Lehmann <gaetan.lehmann@vates.tech>
d87c336 to
686b749
Compare
And make it a bit more robust, by fetching the actual partition mounted on
/Also add support for other Linux distributions than Alpine.
Signed-off-by: Gaëtan Lehmann gaetan.lehmann@vates.tech
This PR is part of a stack containing 2 PRs:
master