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

mount: allow mount with options behind permissions #800

Merged
merged 1 commit into from
Jan 11, 2025

Conversation

tschettervictor
Copy link
Collaborator

Allow mounting with permissions like “rw,other,options” that are needed for tmpfs mounting.

Allow mounting with permissions like “rw,other,options” that are needed for tmpfs mounting.
@yaazkal
Copy link
Collaborator

yaazkal commented Jan 10, 2025

I'll keep the current code. There is no gain in that change and we lost readability.

@yaazkal yaazkal closed this Jan 10, 2025
@tschettervictor
Copy link
Collaborator Author

I'll keep the current code. There is no gain in that change and we lost readability.

Hmm...
We lose a lot without this, namely #504

Current code does not allow mounting with any options other than ro and rw

Thoughts?

@yaazkal
Copy link
Collaborator

yaazkal commented Jan 10, 2025

Sorry @tschettervictor I read it wrong. Reopening for testing.

@yaazkal yaazkal reopened this Jan 10, 2025
@bmac2
Copy link
Collaborator

bmac2 commented Jan 11, 2025

tested good. This does fix the #504 issue with tmp filesystems.

@bmac2 bmac2 merged commit 43dbb3d into BastilleBSD:master Jan 11, 2025
2 checks passed
@tschettervictor tschettervictor deleted the patch-1 branch January 11, 2025 16:27
@yaazkal
Copy link
Collaborator

yaazkal commented Jan 11, 2025

My comment to this change is that the user will be forced to always use ro or rw as the first option, is that how it should be? If so let's add that in documentation.

@tschettervictor
Copy link
Collaborator Author

You bring a valid point.

You are right.

We could either do docs, or do a small tweak to make sure rw or ro is always included in the options.

@bmac2
Copy link
Collaborator

bmac2 commented Jan 11, 2025

do we need to unmerge this one and make that change?? Force them to use rw or ro? or is documentation enough?
@yaazkal @tschettervictor

@tschettervictor
Copy link
Collaborator Author

I've just submitted PR #801 documenting the behaviour.

@yaazkal
Copy link
Collaborator

yaazkal commented Jan 11, 2025

@bmac2 I'll say documentation is enough thinking in the release.

But not sure about if it's preferable by the community to not be force to start wit ro, rw. Anyway is almost an "standard" to have those as the first option.

But if we think if border scenarios, not sure if anyone is using swap mounts, in that case, that will never work as the option is sw or read with quotas wich option is rq (Not sure if those also are valid for jails). Check fstab(5)

@yaazkal
Copy link
Collaborator

yaazkal commented Jan 11, 2025

That said in my previous comment, why we don't make the second option Victor said: check that the basic options are included, in this case as per fstab(5):

"rw": read/write device
"rq": read/write with quotas
"ro": read-only device
"sw": swap device
"xx": ignore totally

That way, we bring a wide solution rather than an different limitation to the subcommand.

What do you think?

@bmac2
Copy link
Collaborator

bmac2 commented Jan 11, 2025

fine by me. @tschettervictor you good with coding that up for this release?

@tschettervictor
Copy link
Collaborator Author

Simple enough. Give me an hour or so to implement it.

@tschettervictor
Copy link
Collaborator Author

#802 @yaazkal

@o-techie o-techie mentioned this pull request Jan 18, 2025
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 this pull request may close these issues.

3 participants