hydra/src
Maximilian Bosch a8b590014b
Fix email notifications for jobsets w/git-inputs
I started to wonder quite recently why Hydra doesn't send email
notifications anymore to me. I saw the following issue in the log of
`hydra-notify.service`:

    May 22 11:57:29 hydra 9bik0bxyxbrklhx6lqwifd6af8kj84va-hydra-notify[1887289]: fatal: unsafe repository ('/var/lib/hydra/scm/git/3e70c16c266ef70dc4198705a688acccf71e932878f178277c9ac47d133cc663' is owned by someone else)
    May 22 11:57:29 hydra 9bik0bxyxbrklhx6lqwifd6af8kj84va-hydra-notify[1887289]: To add an exception for this directory, call:
    May 22 11:57:29 hydra 9bik0bxyxbrklhx6lqwifd6af8kj84va-hydra-notify[1887289]:         git config --global --add safe.directory /var/lib/hydra/scm/git/3e70c16c266ef70dc4198705a688acccf71e932878f178277c9ac47d133cc663
    May 22 11:57:29 hydra 9bik0bxyxbrklhx6lqwifd6af8kj84va-hydra-notify[1886654]: error running build_finished hooks: command `git log --pretty=format:%H%x09%an%x09%ae%x09%at b0c30a7557685d25a8ab3f34fdb775e66db0bc4c..eaf28389fcebc2beca13a802f79b2cca6e9ca309 --git-dir=.git' failed with e>

This is also a problem because of Git's fix for CVE-2022-24765[1], so I
applied the same fix as for Nix[2], by using `--git-dir` which skips the
code-path for the ownership-check[3].

[1] https://lore.kernel.org/git/xmqqv8veb5i6.fsf@gitster.g/
[2] https://github.com/NixOS/nix/pull/6440
[3] To quote `git(1)`:
    > Specifying the location of the ".git" directory using this option
    > (or GIT_DIR environment variable) turns off the repository
    > discovery that tries to find a directory with ".git" subdirectory
2022-05-22 14:14:14 +02:00
..
hydra-eval-jobs fix(hydra-eval-jobs): fix typo 2022-04-29 13:06:16 -04:00
hydra-evaluator Fix deprecation warnings with libpqxx usage 2021-07-05 19:45:25 +01:00
hydra-queue-runner Merge pull request #1173 from DeterminateSystems/queue-runner-exporter 2022-04-07 12:27:33 -04:00
lib Fix email notifications for jobsets w/git-inputs 2022-05-22 14:14:14 +02:00
libhydra fix build against nix 2.7.0 2022-03-29 15:38:24 -04:00
root Merge pull request #1103 from DeterminateSystems/runcommand/dynamic 2022-04-19 10:09:47 -04:00
script Merge pull request #1103 from DeterminateSystems/runcommand/dynamic 2022-04-19 10:09:47 -04:00
sql sql: add enable_dynamic_run_command to the Project as well 2022-02-01 10:58:54 -05:00
ttf Add font for the captcha 2013-03-04 12:16:13 +01:00
Makefile.am Revert "hydra-eval-jobs -> nix eval-hydra-jobs" 2020-02-19 20:36:52 +01:00
Makefile.PL perlcritic: use strict, use warnings 2021-09-06 22:13:33 -04:00