Skip to content

Commit 8bb402f

Browse files
authored
Merge pull request #1 from samueldr/fix/trusted-user
Configure as trusted user
2 parents a55203c + 0b80175 commit 8bb402f

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ on:
33
pull_request:
44
push:
55
branches:
6-
- "**"
6+
- "released"
77

88
jobs:
99
do-it:

README.md

+4-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ Lix GHA Installer Action
99

1010
It mostly just runs [the Lix Installer](https://lix.systems/install/#new-installs)<sup>1</sup>.
1111

12-
We use the `channel:` ref to Nixpkgs instead of the `flake:` ref, as the `flake:` ref may have issues within the GHA ecosystem, regarding rate-limiting.
12+
Some differences:
13+
14+
- We use the `channel:` ref to Nixpkgs instead of the `flake:` ref, as the `flake:` ref may have issues within the GHA ecosystem, regarding rate-limiting.
15+
- We configure the current user as a trusted user.
1316

1417
No options.
1518

do-the-lix-thing

+5-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ set -o pipefail # the return value of a pipeline is the status of
1414

1515
################################################################################
1616
# Constants
17-
REPO_URL="https://github.com/samueldr/lix-gha"
17+
REPO_URL="https://github.com/samueldr/lix-gha-installer-action"
1818
ACTION_NAME="Lix GHA Installer Action"
1919
################################################################################
2020

@@ -128,7 +128,10 @@ set -x
128128

129129
curl -sSf -L https://install.lix.systems/lix | bash -s -- install --no-confirm
130130

131-
< /etc/nix/nix.conf sed -e 's/nixpkgs=flake:nixpkgs/nixpkgs=channel:nixos-unstable/' > tmp.conf
131+
(
132+
< /etc/nix/nix.conf sed -e 's/nixpkgs=flake:nixpkgs/nixpkgs=channel:nixos-unstable/'
133+
printf "trusted-users = root %s\n" "${USER:-}"
134+
) > tmp.conf
132135
sudo mv -v tmp.conf /etc/nix/nix.conf
133136
)
134137

0 commit comments

Comments
 (0)