-
-
Notifications
You must be signed in to change notification settings - Fork 19.8k
.github/workflows: build NixOS/Nixpkgs manuals #106036
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| name: "Build NixOS manual" | ||
|
|
||
| on: | ||
| pull_request_target: | ||
| branches: | ||
| - master | ||
| paths: | ||
| - 'nixos/**' | ||
|
|
||
| jobs: | ||
| nixos: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v2 | ||
| with: | ||
| # pull_request_target checks out the base branch by default | ||
| ref: refs/pull/${{ github.event.pull_request.number }}/merge | ||
| - uses: cachix/install-nix-action@v12 | ||
| with: | ||
| # explicitly enable sandbox | ||
| extra_nix_config: sandbox = true | ||
| - uses: cachix/cachix-action@v8 | ||
| with: | ||
| # This cache is for the nixos/nixpkgs manual builds and should not be trusted or used elsewhere. | ||
| name: nixpkgs-ci | ||
| signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}' | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @domenkozar Do you see any way an attacker could extract the signing key in this case?
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Anybody with nixpkgs push access can extract the signing key easily. Push a commit on a branch with We should make sure that nobody consumes that cache except github actions.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd suggest to delete the cache and generate a new one managed with auth tokens. That will ensure tokens can be revoked without losing the cache. On top of that, until we can give committers only merge access and not direct commit access, about 140 people can extract the key. I don't think anyone would do it on purpose, but hacking 1 of 140 github accounts is not infeasible. I suggest we add explicit note that the cache should not be trusted outside the CI usage.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Done. |
||
| - name: Building NixOS manual | ||
| run: nix-build --option restrict-eval true nixos/release.nix -A manual.x86_64-linux | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| name: "Build Nixpkgs manual" | ||
|
|
||
| on: | ||
| pull_request_target: | ||
| branches: | ||
| - master | ||
| paths: | ||
| - 'doc/**' | ||
|
|
||
| jobs: | ||
| nixpkgs: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v2 | ||
| with: | ||
| # pull_request_target checks out the base branch by default | ||
| ref: refs/pull/${{ github.event.pull_request.number }}/merge | ||
| - uses: cachix/install-nix-action@v12 | ||
| with: | ||
| # explicitly enable sandbox | ||
| extra_nix_config: sandbox = true | ||
| - uses: cachix/cachix-action@v8 | ||
| with: | ||
| # This cache is for the nixos/nixpkgs manual builds and should not be trusted or used elsewhere. | ||
| name: nixpkgs-ci | ||
| signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}' | ||
| - name: Building Nixpkgs manual | ||
| run: nix-build --option restrict-eval true pkgs/top-level/release.nix -A manual |
Uh oh!
There was an error while loading. Please reload this page.