try NIX_EXTRA_CONF

This commit is contained in:
Wolfgang Thaller 2022-01-18 09:30:03 +01:00
parent 636e1a26ec
commit e00d4c692a

View File

@ -139,22 +139,15 @@ jobs:
vmImage: 'macOS-11'
steps:
- script: |
NIX_EXTRA_CONF="trusted-users = root runner"
sh <(curl -L https://nixos.org/nix/install)
echo ============
cat /etc/nix/nix.conf
echo ============
displayName: Install nix
- script: |
. /nix/var/nix/profiles/default/etc/profile.d/nix-daemon.sh
echo "trusted-users = root runner" | sudo tee -a /etc/nix/nix.conf
echo "nix: `pgrep nix-daemon`"
sudo launchctl status org.nixos.nix-daemon
sudo launchctl stop org.nixos.nix-daemon
echo "nix: `pgrep nix-daemon`"
sudo launchctl status org.nixos.nix-daemon
sudo launchctl start org.nixos.nix-daemon
echo "nix: `pgrep nix-daemon`"
sudo launchctl status org.nixos.nix-daemon
sleep 5
echo "nix: `pgrep nix-daemon`"
sudo launchctl status org.nixos.nix-daemon
# echo "trusted-users = root runner" | sudo tee -a /etc/nix/nix.conf
nix-env -iA cachix -f https://cachix.org/api/v1/install
cachix use autc04