Skip to content

Commit

Permalink
..
Browse files Browse the repository at this point in the history
  • Loading branch information
domenkozar committed Jun 16, 2023
1 parent 960774f commit dd50fce
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions install-nix.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,11 @@ add_config() {
}
# Set jobs to number of cores
add_config "max-jobs = auto"
ls -la /etc/ssl
add_config "ssl-cert-file = /etc/ssl/cert.pem"
if [[ $OSTYPE =~ darwin ]]; then
ls -la /etc/ssl
ls -la /etc/ssl/certs
add_config "ssl-cert-file = /etc/ssl/cert.pem"
fi
# Allow binary caches for user
add_config "trusted-users = root ${USER:-}"
# Add github access token
Expand Down Expand Up @@ -80,14 +83,6 @@ done

sh "$workdir/install" "${installer_options[@]}"

if [[ $OSTYPE =~ darwin ]]; then
# macOS needs certificates hints
cert_file=/nix/var/nix/profiles/default/etc/ssl/certs/ca-bundle.crt
echo "NIX_SSL_CERT_FILE=$cert_file" >> "$GITHUB_ENV"
export NIX_SSL_CERT_FILE=$cert_file
sudo launchctl setenv NIX_SSL_CERT_FILE "$cert_file"
fi

# Set paths
echo "/nix/var/nix/profiles/default/bin" >> "$GITHUB_PATH"
# new path for nix 2.14
Expand Down

0 comments on commit dd50fce

Please sign in to comment.