Skip to content
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

Can config.yaml / config.toml be readonly? #533

Closed
cdrage opened this issue Jul 9, 2024 · 1 comment · Fixed by #537
Closed

Can config.yaml / config.toml be readonly? #533

cdrage opened this issue Jul 9, 2024 · 1 comment · Fixed by #537

Comments

@cdrage
Copy link
Contributor

cdrage commented Jul 9, 2024

I don't think bootc-image-builder does anything to the file, could it just be read only?

https://github.com/osbuild/bootc-image-builder?tab=readme-ov-file#-build-config :

sudo podman run \
    --rm \
    -it \
    --privileged \
    --pull=newer \
    --security-opt label=type:unconfined_t \
    -v $(pwd)/config.toml:/config.toml \
    -v $(pwd)/output:/output \
    quay.io/centos-bootc/bootc-image-builder:latest \
    --type qcow2 \
    quay.io/centos-bootc/centos-bootc:stream9

Is it okay to update it to -v $(pwd)/config.toml:/config.toml:ro ?

mvo5 added a commit to mvo5/bootc-image-builder that referenced this issue Jul 10, 2024
As suggested by Charlie Drage (thank you!) this commit makes the
mounting of the `config.{toml,yaml}` read-only via the `:ro`
suffix.

The tests are also updated to validate that this works as expected.

Closes: osbuild#533
@mvo5
Copy link
Collaborator

mvo5 commented Jul 10, 2024

Yes, great suggestion, I opened a PR

mvo5 added a commit to mvo5/bootc-image-builder that referenced this issue Jul 11, 2024
As suggested by Charlie Drage (thank you!) this commit makes the
mounting of the `config.{toml,yaml}` read-only via the `:ro`
suffix.

The tests are also updated to validate that this works as expected.

Closes: osbuild#533
github-merge-queue bot pushed a commit that referenced this issue Jul 11, 2024
As suggested by Charlie Drage (thank you!) this commit makes the
mounting of the `config.{toml,yaml}` read-only via the `:ro`
suffix.

The tests are also updated to validate that this works as expected.

Closes: #533
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants