| 18 May 2024 |
| @arcayr:rascals.net left the room. | 08:14:17 |
| tim joined the room. | 21:01:03 |
tim | Hey people, how can I configure hydra to checkout a private repo through ssh? I have tried adding a ssh key to the hydra user home dir, my project config looks like this:
name | displayname | description | enabled | hidden | owner | homepage | declfile | decltype | declvalue | enable_dynamic_run_command
-----------+-------------+-------------------------------------------+---------+--------+-------+-------------------------------------+-----------+----------+-------------------------------------+----------------------------
nixconfig | nixconfig | System configuration for all my computers | 1 | 0 | admin | https://github.com/timhae/nixconfig | spec.json | git | git@github.com:timhae/nixconfig.git | f
(1 row)
(please excuse the formatting).That unfortunately gives me the following error:
May 18 23:22:24 server hydra-evaluator[376537]: starting evaluation of jobset ‘nixconfig:.jobsets (jobset#1)’ (last checked 300 s ago)
May 18 23:22:26 server hydra-evaluator[377356]: (nixconfig:.jobsets) Fetching input `decl` (git) git@github.com:timhae/nixconfig.git
May 18 23:22:28 server hydra-evaluator[377365]: fatal: ambiguous argument 'master': unknown revision or path not in the working tree.
May 18 23:22:28 server hydra-evaluator[377365]: Use '--' to separate paths from revisions, like this:
May 18 23:22:28 server hydra-evaluator[377365]: 'git <command> [<revision>...] -- [<file>...]'
May 18 23:22:28 server hydra-evaluator[377356]: command `git rev-parse master' failed with exit status 32768 in /var/lib/hydra/scm/git/ccf70cf8803f9584da653030eb51f8fc7f407e5ff30b7d976dc4ba3a1e99afe4 at /nix/store/qf86r75y8pf8y7mqv87vp9jwvq5qpy5y-hydra-2024-03-08/libexec/hydra/lib/Hydra/Helper/Nix.pm line 460.
May 18 23:22:28 server hydra-evaluator[376537]: evaluation of jobset ‘nixconfig:.jobsets (jobset#1)’ failed with exit code 1
which is expected as my default branch is 'main'. How do I tell hydra about that?
| 21:24:49 |
| 19 May 2024 |
vcunat |  Download image.png | 06:55:52 |
vcunat | You just configure that in your jobset.
| 06:55:53 |
vcunat | The error isn't about the repo being private, at all. | 06:56:44 |
vcunat | It's about choosing the branch to check out. | 06:56:55 |
vcunat | (though I'm surprised that it won't just choose the main branch if you don't specify any) | 06:57:38 |
vcunat | * Though I'm surprised that it won't just choose the default branch if you don't specify any, assuming you did select in your github repo that main is your default branch (you can choose any). | 06:58:18 |
tim | thanks, I just read the source and found other parameters as well: https://github.com/NixOS/hydra/blob/master/src/lib/Hydra/Plugin/GitInput.pm#L27 is there any place where this is/should be documented? | 07:22:09 |
| @anarres:catgirl.cloud left the room. | 07:22:25 |
tim | I didn't have a jobset yet (only the project) since I configured the project to look for a declarative input and looking up that failed | 07:24:28 |
vcunat | Ah, I'm afraid I don't have experience with declarative on Hydra. | 07:25:33 |
vcunat | * Ah, I'm afraid I don't have experience with declarative on hydra. | 07:25:38 |
tim | No worries, your feedback helped me solve the issue so thanks for that :) the linked source also says
as an input value use: <name>=<value> without spaces and
specify at least he repo url and branch.
which would have been nice to show up here..
| 07:29:31 |
tim | does someone know what the Open Github Refs declarative input should look like? I currently have timhae nixconfig heads - main but it fails with Error pulling from the github refs API: {"message":"Not Found","documentation_url":"https://docs.github.com/rest/git/refs#list-matching-references"} | 09:51:47 |
tim | curl "https://api.github.com/repos/timhae/nixconfig/git/matching-refs/heads/main" does return something though.. | 09:55:42 |
tim | in case someone encounters the same problem: my issue was that I did not change the owner in the access token configuration snippet from the docs:
<github_authorization>
NixOS = Bearer gha-secret😱secret😱secret😱
</github_authorization>
here NixOS refers to the owner in github, I changed that to timhae and now everything works fine :)
| 11:20:41 |
| 20 May 2024 |
| mei 🌒& changed their display name from ckie (they/them) to mei 🌒&. | 00:08:02 |
tim | yet another hydra question from me: my nixconfig repo has files that are encrypted with git-crypt, can I unlock them on the fly after cloning the repo? If so, how? | 16:55:44 |
| 21 May 2024 |
| bumperboat changed their display name from bumperboat (UTC+8) to bumperboat (UTC+7). | 04:34:23 |
| oliver.falvai joined the room. | 06:22:05 |
| 22 May 2024 |
| NixOS Moderation Bot banned @5m5z3q888q5prxkg:chat.lightnovel-dungeon.de (Suspended until 2024-05-29). | 11:45:55 |
| NixOS Moderation Botchanged room power levels. | 15:26:00 |
| NixOS Moderation Botchanged room power levels. | 15:28:14 |
| 24 May 2024 |
| @lotte:chir.rs changed their profile picture. | 06:41:45 |
| @meetmangukiya:matrix.org left the room. | 06:42:17 |
| 26 May 2024 |
| @samueldr:matrix.org left the room. | 19:51:04 |
| 29 May 2024 |
| NixOS Moderation Bot unbanned @5m5z3q888q5prxkg:chat.lightnovel-dungeon.de. | 12:48:33 |
| raitobezarius changed their display name from raitobezarius to raitobezarius (DECT: 7248). | 17:08:46 |