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

fix impermanence in combination with sysusers/userborn #223

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Mic92
Copy link
Member

@Mic92 Mic92 commented Oct 4, 2024

Both remove user creation from the action phase to a systemd service. This is hopefully also easier to debug, since we now can look at a systemd service instead for log output.

@Mic92 Mic92 marked this pull request as draft October 4, 2024 12:43
@Mic92 Mic92 force-pushed the userborn-support branch 3 times, most recently from af08f1b to 0bc0d03 Compare October 4, 2024 13:08
Both remove user creation from the action phase to a systemd service.
This is hopefully also easier to debug, since we now can look at a
systemd service instead for log output.
@Mic92 Mic92 force-pushed the userborn-support branch 3 times, most recently from d5f21cf to 8495848 Compare October 4, 2024 13:42
No idea how this ever worked, but for me all directories in /persistent
never have the write user/group permissions when freshly created.
This now also ensures that permissions will change if the configuration
changes, which is a nice side effect.
@Mic92 Mic92 marked this pull request as ready for review October 4, 2024 13:51
# synchronize perms between source and target
chown --reference="$realSource" "$target"
chmod --reference="$realSource" "$target"
chown "$user:$group" "$realSource" "$target"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See commit message for reasoning.

@Mic92 Mic92 requested a review from talyz October 4, 2024 13:52
@Mic92
Copy link
Member Author

Mic92 commented Oct 4, 2024

Can be tested with

nix run github:Mic92/userborn-with-impermanence#nixosConfigurations.myhost.config.system.build.vmWithDisko

In the vm do:

ls -la /home/user

to see that permissions and owners are correct now.

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.

1 participant