mirror of
https://github.com/DeterminateSystems/determinate-nix-action.git
synced 2026-07-12 19:03:54 +00:00
Compare commits
8 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c70cb8ae92 | ||
|
|
629b284231 | ||
|
|
8ebfb805c6 | ||
|
|
62e9a81172 | ||
|
|
5784b766b3 | ||
|
|
99dbae7e21 | ||
|
|
29680e33cb | ||
|
|
fdaee25790 |
8 changed files with 60 additions and 43 deletions
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
|
|
@ -11,7 +11,7 @@ jobs:
|
||||||
id-token: "write"
|
id-token: "write"
|
||||||
contents: "read"
|
contents: "read"
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
|
||||||
with:
|
with:
|
||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
- uses: ./.
|
- uses: ./.
|
||||||
|
|
|
||||||
4
.github/workflows/release.yml
vendored
4
.github/workflows/release.yml
vendored
|
|
@ -25,9 +25,7 @@ jobs:
|
||||||
shorttag=$(echo "$VERSION" | cut -d'.' -f1)
|
shorttag=$(echo "$VERSION" | cut -d'.' -f1)
|
||||||
echo "shorttag=$shorttag" >> "$GITHUB_OUTPUT"
|
echo "shorttag=$shorttag" >> "$GITHUB_OUTPUT"
|
||||||
|
|
||||||
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
|
||||||
with:
|
|
||||||
persist-credentials: false
|
|
||||||
- name: Create the short tag
|
- name: Create the short tag
|
||||||
env:
|
env:
|
||||||
SHORTTAG: ${{ steps.check_tag.outputs.shorttag }}
|
SHORTTAG: ${{ steps.check_tag.outputs.shorttag }}
|
||||||
|
|
|
||||||
2
.github/workflows/zizmor.yml
vendored
2
.github/workflows/zizmor.yml
vendored
|
|
@ -15,7 +15,7 @@ jobs:
|
||||||
actions: read
|
actions: read
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
|
||||||
with:
|
with:
|
||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
|
|
||||||
|
|
|
||||||
63
README.md
63
README.md
|
|
@ -52,8 +52,8 @@ jobs:
|
||||||
id-token: write
|
id-token: write
|
||||||
contents: read
|
contents: read
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v6.0.3
|
- uses: actions/checkout@v7.0.0
|
||||||
- uses: DeterminateSystems/determinate-nix-action@main # or v3.21.1 to pin to a release
|
- uses: DeterminateSystems/determinate-nix-action@main # or v3.21.5 to pin to a release
|
||||||
- run: nix build .
|
- run: nix build .
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
@ -67,10 +67,10 @@ jobs:
|
||||||
Unlike `DeterminateSystems/nix-installer-action`, we fully support explicit version pinning for maximum consistency.
|
Unlike `DeterminateSystems/nix-installer-action`, we fully support explicit version pinning for maximum consistency.
|
||||||
This Action is **automatically tagged** for every Determinate Nix release, giving you complete control over your CI environment:
|
This Action is **automatically tagged** for every Determinate Nix release, giving you complete control over your CI environment:
|
||||||
|
|
||||||
📍 Pinning to `DeterminateSystems/determinate-nix-action@v3.21.1` guarantees:
|
📍 Pinning to `DeterminateSystems/determinate-nix-action@v3.21.5` guarantees:
|
||||||
|
|
||||||
- Same `nix-installer-action` revision every time
|
- Same `nix-installer-action` revision every time
|
||||||
- Consistent Determinate Nix v3.21.1 installation
|
- Consistent Determinate Nix v3.21.5 installation
|
||||||
- Reproducible CI workflows, even years later
|
- Reproducible CI workflows, even years later
|
||||||
|
|
||||||
✨ Using `@main` instead? You'll:
|
✨ Using `@main` instead? You'll:
|
||||||
|
|
@ -96,30 +96,37 @@ updates:
|
||||||
|
|
||||||
## ️⚙️ Configuration
|
## ️⚙️ Configuration
|
||||||
|
|
||||||
| Parameter | Description | Required | Default |
|
| Parameter | Description | Required | Default |
|
||||||
|-------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------|----------------------------|
|
|---------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------|----------------------------|
|
||||||
| `extra-conf` | Extra configuration lines for `/etc/nix/nix.conf` (includes `access-tokens` with `secrets.GITHUB_TOKEN` automatically if `github-token` is set) | | |
|
| `extra-conf` | Extra configuration lines for `/etc/nix/nix.conf` (includes `access-tokens` with `secrets.GITHUB_TOKEN` automatically if `github-token` is set) | | |
|
||||||
| `github-server-url` | The URL for the GitHub server, to use with the `github-token` token. Defaults to the current GitHub server, supporting GitHub Enterprise Server automatically. Only change this value if the provided `github-token` is for a different GitHub server than the current server. | | `${{ github.server_url }}` |
|
| `github-server-url` | The URL for the GitHub server, to use with the `github-token` token. Defaults to the current GitHub server, supporting GitHub Enterprise Server automatically. Only change this value if the provided `github-token` is for a different GitHub server than the current server. | | `${{ github.server_url }}` |
|
||||||
| `github-token` | A GitHub token for making authenticated requests (which have a higher rate-limit quota than unauthenticated requests) | | `${{ github.token }}` |
|
| `github-token` | A GitHub token for making authenticated requests (which have a higher rate-limit quota than unauthenticated requests) | | `${{ github.token }}` |
|
||||||
| `trust-runner-user` | Whether to make the runner user trusted by the Nix daemon | | `true` |
|
| `trust-runner-user` | Whether to make the runner user trusted by the Nix daemon | | `true` |
|
||||||
| `summarize` | Whether to add a build summary and timeline chart to the GitHub job summary | | `true` |
|
| `summarize` | Whether to add a build summary and timeline chart to the GitHub job summary | | `true` |
|
||||||
| `force-no-systemd` | Force using other methods than systemd to launch the daemon. This setting is automatically enabled when necessary. | | `false` |
|
| `force-no-systemd` | Force using other methods than systemd to launch the daemon. This setting is automatically enabled when necessary. | | `false` |
|
||||||
| `init` | The init system to configure, requires `planner: linux-multi` (allowing the choice between `none` or `systemd`) | | |
|
| `init` | The init system to configure, requires `planner: linux-multi` (allowing the choice between `none` or `systemd`) | | |
|
||||||
| `kvm` | Automatically configure the GitHub Actions Runner for NixOS test supports, if the host supports it. | | `true` |
|
| `kvm` | Automatically configure the GitHub Actions Runner for NixOS test supports, if the host supports it. | | `true` |
|
||||||
| `planner` | A planner to use | | |
|
| `planner` | A planner to use | | |
|
||||||
| `proxy` | The proxy to use (if any), valid proxy bases are `https://$URL`, `http://$URL` and `socks5://$URL` | | |
|
| `proxy` | The proxy to use (if any), valid proxy bases are `https://$URL`, `http://$URL` and `socks5://$URL` | | |
|
||||||
| `reinstall` | Force a reinstall if an existing installation is detected (consider backing up `/nix/store`) | | `false` |
|
| `reinstall` | Force a reinstall if an existing installation is detected (consider backing up `/nix/store`) | | `false` |
|
||||||
| `source-binary` | Run a version of the nix-installer binary from somewhere already on disk. Conflicts with all other `source-*` options. Intended only for testing this Action. | | |
|
| `source-binary` | Run a version of the nix-installer binary from somewhere already on disk. Conflicts with all other `source-*` options. Intended only for testing this Action. | | |
|
||||||
| `source-branch` | The branch of `nix-installer` to use (conflicts with `source-tag`, `source-revision`, `source-pr`) | | |
|
| `source-branch` | The branch of `nix-installer` to use (conflicts with `source-tag`, `source-revision`, `source-pr`) | | |
|
||||||
| `source-pr` | The PR of `nix-installer` to use (conflicts with `source-tag`, `source-revision`, `source-branch`) | | |
|
| `source-pr` | The PR of `nix-installer` to use (conflicts with `source-tag`, `source-revision`, `source-branch`) | | |
|
||||||
| `source-revision` | The revision of `nix-installer` to use (conflicts with `source-tag`, `source-branch`, `source-pr`) | | |
|
| `source-revision` | The revision of `nix-installer` to use (conflicts with `source-tag`, `source-branch`, `source-pr`) | | |
|
||||||
| `source-tag` | The tag of `nix-installer` to use (conflicts with `source-revision`, `source-branch`, `source-pr`) | | `v3.21.1` |
|
| `source-tag` | The tag of `nix-installer` to use (conflicts with `source-revision`, `source-branch`, `source-pr`) | | `v3.21.5` |
|
||||||
| `source-url` | A URL pointing to a `nix-installer` executable | | |
|
| `source-url` | A URL pointing to a `nix-installer` executable | | |
|
||||||
| `backtrace` | The setting for `RUST_BACKTRACE` (see https://doc.rust-lang.org/std/backtrace/index.html#environment-variables) | | |
|
| `source-checksums-url` | URL of a `shasum`-format checksums file listing the SHA-256 of each
|
||||||
| `diagnostic-endpoint` | Diagnostic endpoint url where the installer sends data to. To disable set this to an empty string. | | `-` |
|
`nix-installer-<arch>-<os>` artifact. Used together with
|
||||||
| `log-directives` | A list of Tracing directives, comma separated, `-`s replaced with `_` (eg. `nix_installer=trace`, see https://docs.rs/tracing-subscriber/latest/tracing_subscriber/filter/struct.EnvFilter.html#directives) | | |
|
`source-checksums-sha256` to verify the downloaded installer.
|
||||||
| `logger` | The logger to use for install (eg. `pretty`, `json`, `full`, `compact`) | | |
|
| | |
|
||||||
| `_internal-strict-mode` | Whether to fail when any errors are thrown. Used only to test the Action; do not set this in your own workflows. | | `false` |
|
| `source-checksums-sha256` | Pinned SHA-256 (hex) of the file served at `source-checksums-url`. Must
|
||||||
|
be set together with `source-checksums-url`.
|
||||||
|
| | |
|
||||||
|
| `backtrace` | The setting for `RUST_BACKTRACE` (see https://doc.rust-lang.org/std/backtrace/index.html#environment-variables) | | |
|
||||||
|
| `diagnostic-endpoint` | Diagnostic endpoint url where the installer sends data to. To disable set this to an empty string. | | `-` |
|
||||||
|
| `log-directives` | A list of Tracing directives, comma separated, `-`s replaced with `_` (eg. `nix_installer=trace`, see https://docs.rs/tracing-subscriber/latest/tracing_subscriber/filter/struct.EnvFilter.html#directives) | | |
|
||||||
|
| `logger` | The logger to use for install (eg. `pretty`, `json`, `full`, `compact`) | | |
|
||||||
|
| `_internal-strict-mode` | Whether to fail when any errors are thrown. Used only to test the Action; do not set this in your own workflows. | | `false` |
|
||||||
|
|
||||||
## 🛟 Need help? We're here for you!
|
## 🛟 Need help? We're here for you!
|
||||||
|
|
||||||
|
|
|
||||||
14
action.yml
14
action.yml
|
|
@ -72,12 +72,20 @@
|
||||||
"source-tag": {
|
"source-tag": {
|
||||||
"description": "The tag of `nix-installer` to use (conflicts with `source-revision`, `source-branch`, `source-pr`)",
|
"description": "The tag of `nix-installer` to use (conflicts with `source-revision`, `source-branch`, `source-pr`)",
|
||||||
"required": false,
|
"required": false,
|
||||||
"default": "v3.21.1"
|
"default": "v3.21.5"
|
||||||
},
|
},
|
||||||
"source-url": {
|
"source-url": {
|
||||||
"description": "A URL pointing to a `nix-installer` executable",
|
"description": "A URL pointing to a `nix-installer` executable",
|
||||||
"required": false
|
"required": false
|
||||||
},
|
},
|
||||||
|
"source-checksums-url": {
|
||||||
|
"description": "URL of a `shasum`-format checksums file listing the SHA-256 of each\n`nix-installer-<arch>-<os>` artifact. Used together with\n`source-checksums-sha256` to verify the downloaded installer.\n",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
|
"source-checksums-sha256": {
|
||||||
|
"description": "Pinned SHA-256 (hex) of the file served at `source-checksums-url`. Must\nbe set together with `source-checksums-url`.\n",
|
||||||
|
"required": false
|
||||||
|
},
|
||||||
"backtrace": {
|
"backtrace": {
|
||||||
"description": "The setting for `RUST_BACKTRACE` (see https://doc.rust-lang.org/std/backtrace/index.html#environment-variables)",
|
"description": "The setting for `RUST_BACKTRACE` (see https://doc.rust-lang.org/std/backtrace/index.html#environment-variables)",
|
||||||
"required": false
|
"required": false
|
||||||
|
|
@ -105,7 +113,7 @@
|
||||||
"using": "composite",
|
"using": "composite",
|
||||||
"steps": [
|
"steps": [
|
||||||
{
|
{
|
||||||
"uses": "DeterminateSystems/nix-installer-action@1d87d45818068401a10cf16bdc5f00b24994a83f",
|
"uses": "DeterminateSystems/nix-installer-action@a7ad9c4f0c65208097f4d34f3cfa1913b80cce5c",
|
||||||
"with": {
|
"with": {
|
||||||
"extra-conf": "${{ inputs.extra-conf }}",
|
"extra-conf": "${{ inputs.extra-conf }}",
|
||||||
"github-server-url": "${{ inputs.github-server-url }}",
|
"github-server-url": "${{ inputs.github-server-url }}",
|
||||||
|
|
@ -124,6 +132,8 @@
|
||||||
"source-revision": "${{ inputs.source-revision }}",
|
"source-revision": "${{ inputs.source-revision }}",
|
||||||
"source-tag": "${{ inputs.source-tag }}",
|
"source-tag": "${{ inputs.source-tag }}",
|
||||||
"source-url": "${{ inputs.source-url }}",
|
"source-url": "${{ inputs.source-url }}",
|
||||||
|
"source-checksums-url": "${{ inputs.source-checksums-url }}",
|
||||||
|
"source-checksums-sha256": "${{ inputs.source-checksums-sha256 }}",
|
||||||
"backtrace": "${{ inputs.backtrace }}",
|
"backtrace": "${{ inputs.backtrace }}",
|
||||||
"diagnostic-endpoint": "${{ inputs.diagnostic-endpoint }}",
|
"diagnostic-endpoint": "${{ inputs.diagnostic-endpoint }}",
|
||||||
"log-directives": "${{ inputs.log-directives }}",
|
"log-directives": "${{ inputs.log-directives }}",
|
||||||
|
|
|
||||||
10
flake.lock
generated
10
flake.lock
generated
|
|
@ -2,12 +2,12 @@
|
||||||
"nodes": {
|
"nodes": {
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1780749050,
|
"lastModified": 1783224372,
|
||||||
"narHash": "sha256-3av0pIjlOWQ6rDbNOmpUSvbNnJkGORQKKjb4LtCZsIY=",
|
"narHash": "sha256-8i/87eeoqiGE4yOTjwSA3Eh/ziJRQEmd/unYU+K27sk=",
|
||||||
"rev": "a799d3e3886da994fa307f817a6bc705ae538eeb",
|
"rev": "d407951447dcd00442e97087bf374aad70c04cea",
|
||||||
"revCount": 1011622,
|
"revCount": 1027867,
|
||||||
"type": "tarball",
|
"type": "tarball",
|
||||||
"url": "https://api.flakehub.com/f/pinned/NixOS/nixpkgs/0.1.1011622%2Brev-a799d3e3886da994fa307f817a6bc705ae538eeb/019ea4be-9303-7001-8232-6b7ec45c4f5b/source.tar.gz"
|
"url": "https://api.flakehub.com/f/pinned/NixOS/nixpkgs/0.1.1027867%2Brev-d407951447dcd00442e97087bf374aad70c04cea/019f32d6-f801-7201-b6cb-59773d7eec95/source.tar.gz"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"type": "tarball",
|
"type": "tarball",
|
||||||
|
|
|
||||||
|
|
@ -74,6 +74,8 @@ keep_inputs = [
|
||||||
"source-revision",
|
"source-revision",
|
||||||
"source-tag",
|
"source-tag",
|
||||||
"source-url",
|
"source-url",
|
||||||
|
"source-checksums-url",
|
||||||
|
"source-checksums-sha256",
|
||||||
# debugging
|
# debugging
|
||||||
"backtrace",
|
"backtrace",
|
||||||
"diagnostic-endpoint",
|
"diagnostic-endpoint",
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"nix_installer_action_revision": "1d87d45818068401a10cf16bdc5f00b24994a83f",
|
"nix_installer_action_revision": "a7ad9c4f0c65208097f4d34f3cfa1913b80cce5c",
|
||||||
"determinate_nix_tag": "v3.21.1",
|
"determinate_nix_tag": "v3.21.5",
|
||||||
"checkout_action_tag": "v6.0.3"
|
"checkout_action_tag": "v7.0.0"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue