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

Prototype of multi-agents module for nix-darwin #586

Closed
wants to merge 1 commit into from

Conversation

avnik
Copy link

@avnik avnik commented Mar 27, 2024

This effort is a bit incomplete, due lack of mac osx experience and nix-darwin knowledge.

  1. All agents by default run from same user (I have no idea how to generate uids for each agent, as well as have no idea about knowUsers statements and underscored names). But also here a "handle" to assign explicit user to each agent.

  2. Some path is hardcoded (common base directory), as well as usernames.

Both criticizing and advices are welcomed

@avnik avnik marked this pull request as draft March 27, 2024 20:12
@avnik avnik force-pushed the avnik/darwin-multi branch 11 times, most recently from b83ba41 to 4ea7a7c Compare March 29, 2024 17:39
Copy link

@aciceri aciceri left a comment

Choose a reason for hiding this comment

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

I don't have much experience with nix on mac but everything looks perfectly reasonable. Moreover I can confirm it seems to work.


nix.settings.trusted-users = [ cfg.user ];

system.activationScripts.preActivation.text = ''
Copy link

Choose a reason for hiding this comment

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

I would suggest to use a different name that refers to hercules-ci for the activation script.

Copy link
Author

Choose a reason for hiding this comment

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

preActivation is a proper name for nix-darwin (it have set of predefined names, which later substituted, I can't use arbitrary name -- https://github.com/LnL7/nix-darwin/blob/master/modules/system/activation-scripts.nix#L53 )

Copy link

Choose a reason for hiding this comment

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

Interesting...I didn't know. Their types is types.lines so they merge well if someone else sets preActivation (which was my main concern).

Copy link
Author

Choose a reason for hiding this comment

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

Resolve it if all ok. I rebased/squashed commits

@avnik avnik marked this pull request as ready for review May 8, 2024 15:05
@avnik avnik requested a review from aciceri May 8, 2024 15:05
@avnik
Copy link
Author

avnik commented Aug 22, 2024

Replaced by #609

@avnik avnik closed this Aug 22, 2024
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.

2 participants