-
Notifications
You must be signed in to change notification settings - Fork 130
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
untar fdi-image as proxy user/group #774
base: master
Are you sure you want to change the base?
Conversation
@ekohl Is it possible to introduce |
d6a96a8
to
99c0969
Compare
ee13da7
to
b1e101f
Compare
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'm unsure about adding a dependency since I like to keep the dependencies light. On the other hand, I do see the benefit of using checksums.
https://puppet.com/docs/puppet/7/type.html#file-attribute-checksum doesn't appear to be what you want and I can't determine if https://puppet.com/docs/puppet/7/type.html#file-attribute-checksum_value is either.
As this lookup may have useful for other/future acceptance tests.
To prevent fdi-image files from being chown'd on subsequent puppet agent runs.
b1e101f
to
4d45394
Compare
I'm not sure how to use those params to achieve a digest validation of a downloaded file. I suppose it might be possible to use the path of downloaded file as the |
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 forgot this for a while. Is there any reason this should be owned by foreman-proxy
rather than root
?
That is a good question. I don't think foreman tries to download and replace the image file so it could be |
Do you want me to change the ownership? |
I'd prefer root. The only downside is that |
I just ran into the current logic not unpackaging the tarball if the |
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.
Something else to consider: in theory it's also possible to build a proper package instead of having to retrieve a tarball. It's actually what we do in downstream and would align much better.
To open that discussion I started theforeman/foreman-packaging#8929.
).without( | ||
).that_requires('Exec[mkdir -p /tmp]') |
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.
).without( | |
).that_requires('Exec[mkdir -p /tmp]') | |
).that_requires('Exec[mkdir -p /tmp]') |
I general prefer using the package manager, when possible, but that is a bit of a heavy weight solution... I think we need to the ability to download images, at least for testing. |
I just ran into this as well when trying to update the FDI tar file. It's because of the
Seems like the |
Previously, if you change the image_name (such as for updating the Foreman Discovery Image version), the new tar file would be downloaded but not untarred because the content of the previous tar file would be there and pass the `creates` check. If we use `refreshonly` instead of `creates`, the untar exec will be executed when the tar file is updated, as expected. See also: theforeman#774 (comment)
Previously, if you change the image_name (such as for updating the Foreman Discovery Image version), the new tar file would be downloaded but not untarred because the content of the previous tar file would be there and pass the `creates` check. If we use `refreshonly` instead of `creates`, the untar exec will be executed when the tar file is updated, as expected. See also: theforeman#774 (comment)
Previously, if you change the image_name (such as for updating the Foreman Discovery Image version), the new tar file would be downloaded but not untarred because the content of the previous tar file would be there and pass the `creates` check. If we use `refreshonly` instead of `creates`, the untar exec will be executed when the tar file is updated, as expected. See also: theforeman#774 (comment)
Previously, if you change the image_name (such as for updating the Foreman Discovery Image version), the new tar file would be downloaded but not untarred because the content of the previous tar file would be there and pass the `creates` check. If we use `refreshonly` instead of `creates`, the untar exec will be executed when the tar file is updated, as expected. See also: theforeman#774 (comment)
Previously, if you change the image_name (such as for updating the Foreman Discovery Image version), the new tar file would be downloaded but not untarred because the content of the previous tar file would be there and pass the `creates` check. If we use `refreshonly` instead of `creates`, the untar exec will be executed when the tar file is updated, as expected. See also: theforeman#774 (comment)
To prevent fdi-image files from being chown'd on subsequent puppet agent
runs.