Skip to content

Node name cannot contain . #307

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

Open
ReneHollander opened this issue Dec 25, 2024 · 4 comments
Open

Node name cannot contain . #307

ReneHollander opened this issue Dec 25, 2024 · 4 comments

Comments

@ReneHollander
Copy link

ReneHollander commented Dec 25, 2024

Hello!

The node name cannot contain a . character:

[rene@renespc:~/repositories/infra]$ nix run github:serokell/deploy-rs -- -d .#"chwei01.serv0r.xyz"
πŸš€ ❌ [deploy] [ERROR] Error parsing flake: Unrecognized node or token encountered

I would like to do that because it allows me to have the same name between hostname, nixosConfiguration and the deploy rs configuration.

@ReneHollander
Copy link
Author

As per usual I figured it out a few minutes later: deploy-rs does not like the node name to contain ..

Updated the issue title accordingly.

@ReneHollander ReneHollander changed the title Unrecognized node or token encountered Node name cannot contain . Dec 25, 2024
@Munksgaard
Copy link

You can fix this by wrapping the node name in single quotes and adding a dot at the end:

nix run github:serokell/deploy-rs -- -d '.#"chwei01.serv0r.xyz".'

@Chaostheorie
Copy link

deploy-rs appears to parse the node names as flake paths. This means when you specify .#my.awesome.node you don't reference deploy.nodes."my.awesome.node" but instead deploy.nodes.my.awesome.node. The code interpreting the AST from the parser stops the moment it sees neither an indent nor a string, which is why you are shown a ParseFlakeError::Unrecognized error.

Chaostheorie added a commit to Chaostheorie/deploy-rs that referenced this issue Mar 27, 2025
Extend ast handling for nodename with dots, see serokell#307
@Chaostheorie
Copy link

Chaostheorie commented Mar 27, 2025

#317 fixes this, now --targets .#info.archive.org. should reference the node info.archive.org with the default profile. The fix was easier than expected.

Chaostheorie added a commit to Chaostheorie/deploy-rs that referenced this issue Mar 28, 2025
Extend ast handling for nodename with dots, see serokell#307
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

No branches or pull requests

4 participants
@Munksgaard @ReneHollander @Chaostheorie and others