mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 04:19:19 -08:00
chore(ci): update to 0.7
This commit is contained in:
parent
a0ae2325d6
commit
2f4719811b
6 changed files with 57 additions and 201 deletions
31
.github/workflows/flake-update.yml
vendored
31
.github/workflows/flake-update.yml
vendored
|
|
@ -10,22 +10,22 @@ jobs:
|
|||
steps:
|
||||
- id: checkout
|
||||
name: git clone
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: false
|
||||
- id: nix-install
|
||||
name: nix install
|
||||
uses: arcnmx/ci/actions/nix/install@v0.6
|
||||
uses: arcnmx/ci/actions/nix/install@v0.7
|
||||
- id: ci-action-build
|
||||
name: nix build ci.gh-actions.configFile
|
||||
uses: arcnmx/ci/actions/nix/build@v0.6
|
||||
uses: arcnmx/ci/actions/nix/build@v0.7
|
||||
with:
|
||||
attrs: ci.gh-actions.configFile
|
||||
out-link: .ci/workflow.yml
|
||||
- id: ci-action-compare
|
||||
name: gh-actions compare
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
args: -u .github/workflows/flake-update.yml .ci/workflow.yml
|
||||
attrs: nixpkgs.diffutils
|
||||
|
|
@ -36,27 +36,16 @@ jobs:
|
|||
steps:
|
||||
- id: checkout
|
||||
name: git clone
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: false
|
||||
- id: nix-install
|
||||
name: nix install
|
||||
uses: arcnmx/ci/actions/nix/install@v0.6
|
||||
- id: ci-setup
|
||||
name: nix setup
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
with:
|
||||
attrs: ci.job.flake-update.run.bootstrap
|
||||
quiet: false
|
||||
- id: architectures
|
||||
name: prepare for emulated builds
|
||||
run: 'sudo $(which archbinfmt)
|
||||
|
||||
'
|
||||
uses: arcnmx/ci/actions/nix/install@v0.7
|
||||
- id: ci-dirty
|
||||
name: nix test dirty
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.flake-update.run.test
|
||||
command: ci-build-dirty
|
||||
|
|
@ -64,7 +53,7 @@ jobs:
|
|||
stdout: ${{ runner.temp }}/ci.build.dirty
|
||||
- id: ci-test
|
||||
name: nix test build
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.flake-update.run.test
|
||||
command: ci-build-realise
|
||||
|
|
@ -75,7 +64,7 @@ jobs:
|
|||
CI_EXIT_CODE: ${{ steps.ci-test.outputs.exit-code }}
|
||||
id: ci-summary
|
||||
name: nix test results
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.flake-update.run.test
|
||||
command: ci-build-summarise
|
||||
|
|
@ -87,7 +76,7 @@ jobs:
|
|||
id: ci-cache
|
||||
if: always()
|
||||
name: nix test cache
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.flake-update.run.test
|
||||
command: ci-build-cache
|
||||
|
|
|
|||
146
.github/workflows/nodes.yml
vendored
146
.github/workflows/nodes.yml
vendored
|
|
@ -9,26 +9,15 @@ jobs:
|
|||
steps:
|
||||
- id: checkout
|
||||
name: git clone
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: false
|
||||
- id: nix-install
|
||||
name: nix install
|
||||
uses: arcnmx/ci/actions/nix/install@v0.6
|
||||
- id: ci-setup
|
||||
name: nix setup
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
with:
|
||||
attrs: ci.job.aya.run.bootstrap
|
||||
quiet: false
|
||||
- id: architectures
|
||||
name: prepare for emulated builds
|
||||
run: 'sudo $(which archbinfmt)
|
||||
|
||||
'
|
||||
uses: arcnmx/ci/actions/nix/install@v0.7
|
||||
- id: ci-dirty
|
||||
name: nix test dirty
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.aya.run.test
|
||||
command: ci-build-dirty
|
||||
|
|
@ -36,7 +25,7 @@ jobs:
|
|||
stdout: ${{ runner.temp }}/ci.build.dirty
|
||||
- id: ci-test
|
||||
name: nix test build
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.aya.run.test
|
||||
command: ci-build-realise
|
||||
|
|
@ -47,7 +36,7 @@ jobs:
|
|||
CI_EXIT_CODE: ${{ steps.ci-test.outputs.exit-code }}
|
||||
id: ci-summary
|
||||
name: nix test results
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.aya.run.test
|
||||
command: ci-build-summarise
|
||||
|
|
@ -59,7 +48,7 @@ jobs:
|
|||
id: ci-cache
|
||||
if: always()
|
||||
name: nix test cache
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.aya.run.test
|
||||
command: ci-build-cache
|
||||
|
|
@ -71,21 +60,21 @@ jobs:
|
|||
steps:
|
||||
- id: checkout
|
||||
name: git clone
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: false
|
||||
- id: nix-install
|
||||
name: nix install
|
||||
uses: arcnmx/ci/actions/nix/install@v0.6
|
||||
uses: arcnmx/ci/actions/nix/install@v0.7
|
||||
- id: ci-action-build
|
||||
name: nix build ci.gh-actions.configFile
|
||||
uses: arcnmx/ci/actions/nix/build@v0.6
|
||||
uses: arcnmx/ci/actions/nix/build@v0.7
|
||||
with:
|
||||
attrs: ci.gh-actions.configFile
|
||||
out-link: .ci/workflow.yml
|
||||
- id: ci-action-compare
|
||||
name: gh-actions compare
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
args: -u .github/workflows/nodes.yml .ci/workflow.yml
|
||||
attrs: nixpkgs.diffutils
|
||||
|
|
@ -96,26 +85,15 @@ jobs:
|
|||
steps:
|
||||
- id: checkout
|
||||
name: git clone
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: false
|
||||
- id: nix-install
|
||||
name: nix install
|
||||
uses: arcnmx/ci/actions/nix/install@v0.6
|
||||
- id: ci-setup
|
||||
name: nix setup
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
with:
|
||||
attrs: ci.job.ct.run.bootstrap
|
||||
quiet: false
|
||||
- id: architectures
|
||||
name: prepare for emulated builds
|
||||
run: 'sudo $(which archbinfmt)
|
||||
|
||||
'
|
||||
uses: arcnmx/ci/actions/nix/install@v0.7
|
||||
- id: ci-dirty
|
||||
name: nix test dirty
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.ct.run.test
|
||||
command: ci-build-dirty
|
||||
|
|
@ -123,7 +101,7 @@ jobs:
|
|||
stdout: ${{ runner.temp }}/ci.build.dirty
|
||||
- id: ci-test
|
||||
name: nix test build
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.ct.run.test
|
||||
command: ci-build-realise
|
||||
|
|
@ -134,7 +112,7 @@ jobs:
|
|||
CI_EXIT_CODE: ${{ steps.ci-test.outputs.exit-code }}
|
||||
id: ci-summary
|
||||
name: nix test results
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.ct.run.test
|
||||
command: ci-build-summarise
|
||||
|
|
@ -146,7 +124,7 @@ jobs:
|
|||
id: ci-cache
|
||||
if: always()
|
||||
name: nix test cache
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.ct.run.test
|
||||
command: ci-build-cache
|
||||
|
|
@ -158,26 +136,15 @@ jobs:
|
|||
steps:
|
||||
- id: checkout
|
||||
name: git clone
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: false
|
||||
- id: nix-install
|
||||
name: nix install
|
||||
uses: arcnmx/ci/actions/nix/install@v0.6
|
||||
- id: ci-setup
|
||||
name: nix setup
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
with:
|
||||
attrs: ci.job.hakurei.run.bootstrap
|
||||
quiet: false
|
||||
- id: architectures
|
||||
name: prepare for emulated builds
|
||||
run: 'sudo $(which archbinfmt)
|
||||
|
||||
'
|
||||
uses: arcnmx/ci/actions/nix/install@v0.7
|
||||
- id: ci-dirty
|
||||
name: nix test dirty
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.hakurei.run.test
|
||||
command: ci-build-dirty
|
||||
|
|
@ -185,7 +152,7 @@ jobs:
|
|||
stdout: ${{ runner.temp }}/ci.build.dirty
|
||||
- id: ci-test
|
||||
name: nix test build
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.hakurei.run.test
|
||||
command: ci-build-realise
|
||||
|
|
@ -196,7 +163,7 @@ jobs:
|
|||
CI_EXIT_CODE: ${{ steps.ci-test.outputs.exit-code }}
|
||||
id: ci-summary
|
||||
name: nix test results
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.hakurei.run.test
|
||||
command: ci-build-summarise
|
||||
|
|
@ -208,7 +175,7 @@ jobs:
|
|||
id: ci-cache
|
||||
if: always()
|
||||
name: nix test cache
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.hakurei.run.test
|
||||
command: ci-build-cache
|
||||
|
|
@ -220,26 +187,15 @@ jobs:
|
|||
steps:
|
||||
- id: checkout
|
||||
name: git clone
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: false
|
||||
- id: nix-install
|
||||
name: nix install
|
||||
uses: arcnmx/ci/actions/nix/install@v0.6
|
||||
- id: ci-setup
|
||||
name: nix setup
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
with:
|
||||
attrs: ci.job.mediabox.run.bootstrap
|
||||
quiet: false
|
||||
- id: architectures
|
||||
name: prepare for emulated builds
|
||||
run: 'sudo $(which archbinfmt)
|
||||
|
||||
'
|
||||
uses: arcnmx/ci/actions/nix/install@v0.7
|
||||
- id: ci-dirty
|
||||
name: nix test dirty
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.mediabox.run.test
|
||||
command: ci-build-dirty
|
||||
|
|
@ -247,7 +203,7 @@ jobs:
|
|||
stdout: ${{ runner.temp }}/ci.build.dirty
|
||||
- id: ci-test
|
||||
name: nix test build
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.mediabox.run.test
|
||||
command: ci-build-realise
|
||||
|
|
@ -258,7 +214,7 @@ jobs:
|
|||
CI_EXIT_CODE: ${{ steps.ci-test.outputs.exit-code }}
|
||||
id: ci-summary
|
||||
name: nix test results
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.mediabox.run.test
|
||||
command: ci-build-summarise
|
||||
|
|
@ -270,7 +226,7 @@ jobs:
|
|||
id: ci-cache
|
||||
if: always()
|
||||
name: nix test cache
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.mediabox.run.test
|
||||
command: ci-build-cache
|
||||
|
|
@ -282,26 +238,15 @@ jobs:
|
|||
steps:
|
||||
- id: checkout
|
||||
name: git clone
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: false
|
||||
- id: nix-install
|
||||
name: nix install
|
||||
uses: arcnmx/ci/actions/nix/install@v0.6
|
||||
- id: ci-setup
|
||||
name: nix setup
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
with:
|
||||
attrs: ci.job.reimu.run.bootstrap
|
||||
quiet: false
|
||||
- id: architectures
|
||||
name: prepare for emulated builds
|
||||
run: 'sudo $(which archbinfmt)
|
||||
|
||||
'
|
||||
uses: arcnmx/ci/actions/nix/install@v0.7
|
||||
- id: ci-dirty
|
||||
name: nix test dirty
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.reimu.run.test
|
||||
command: ci-build-dirty
|
||||
|
|
@ -309,7 +254,7 @@ jobs:
|
|||
stdout: ${{ runner.temp }}/ci.build.dirty
|
||||
- id: ci-test
|
||||
name: nix test build
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.reimu.run.test
|
||||
command: ci-build-realise
|
||||
|
|
@ -320,7 +265,7 @@ jobs:
|
|||
CI_EXIT_CODE: ${{ steps.ci-test.outputs.exit-code }}
|
||||
id: ci-summary
|
||||
name: nix test results
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.reimu.run.test
|
||||
command: ci-build-summarise
|
||||
|
|
@ -332,7 +277,7 @@ jobs:
|
|||
id: ci-cache
|
||||
if: always()
|
||||
name: nix test cache
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.reimu.run.test
|
||||
command: ci-build-cache
|
||||
|
|
@ -344,26 +289,15 @@ jobs:
|
|||
steps:
|
||||
- id: checkout
|
||||
name: git clone
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: false
|
||||
- id: nix-install
|
||||
name: nix install
|
||||
uses: arcnmx/ci/actions/nix/install@v0.6
|
||||
- id: ci-setup
|
||||
name: nix setup
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
with:
|
||||
attrs: ci.job.tei.run.bootstrap
|
||||
quiet: false
|
||||
- id: architectures
|
||||
name: prepare for emulated builds
|
||||
run: 'sudo $(which archbinfmt)
|
||||
|
||||
'
|
||||
uses: arcnmx/ci/actions/nix/install@v0.7
|
||||
- id: ci-dirty
|
||||
name: nix test dirty
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.tei.run.test
|
||||
command: ci-build-dirty
|
||||
|
|
@ -371,7 +305,7 @@ jobs:
|
|||
stdout: ${{ runner.temp }}/ci.build.dirty
|
||||
- id: ci-test
|
||||
name: nix test build
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.tei.run.test
|
||||
command: ci-build-realise
|
||||
|
|
@ -382,7 +316,7 @@ jobs:
|
|||
CI_EXIT_CODE: ${{ steps.ci-test.outputs.exit-code }}
|
||||
id: ci-summary
|
||||
name: nix test results
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.tei.run.test
|
||||
command: ci-build-summarise
|
||||
|
|
@ -394,7 +328,7 @@ jobs:
|
|||
id: ci-cache
|
||||
if: always()
|
||||
name: nix test cache
|
||||
uses: arcnmx/ci/actions/nix/run@v0.6
|
||||
uses: arcnmx/ci/actions/nix/run@v0.7
|
||||
with:
|
||||
attrs: ci.job.tei.run.test
|
||||
command: ci-build-cache
|
||||
|
|
|
|||
|
|
@ -12,10 +12,9 @@ in {
|
|||
nixpkgs.args.localSystem = "x86_64-linux";
|
||||
|
||||
ci = {
|
||||
version = "v0.6";
|
||||
version = "v0.7";
|
||||
gh-actions = {
|
||||
enable = true;
|
||||
export = true;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
@ -27,28 +26,6 @@ in {
|
|||
#extra-sandbox-paths = with channels.cipkgs; map (package: builtins.unsafeDiscardStringContext "${package}?") [bash qemu "/run/binfmt"];
|
||||
};
|
||||
|
||||
environment.bootstrap = {
|
||||
archbinfmt = let
|
||||
makeQemuWrapper = name: ''
|
||||
mkdir -p /run/binfmt
|
||||
rm -f /run/binfmt/${name}-linux
|
||||
cat > /run/binfmt/${name}-linux << 'EOF'
|
||||
#!${channels.cipkgs.bash}/bin/sh
|
||||
exec -- ${channels.cipkgs.qemu}/bin/qemu-${name} "$@"
|
||||
EOF
|
||||
chmod +x /run/binfmt/${name}-linux
|
||||
'';
|
||||
in
|
||||
channels.cipkgs.writeShellScriptBin "archbinfmt" ''
|
||||
${makeQemuWrapper "aarch64"}
|
||||
${makeQemuWrapper "arm"}
|
||||
echo 'extra-sandbox-paths = ${channels.cipkgs.bash} ${channels.cipkgs.qemu} /run/binfmt' >> /etc/nix/nix.conf
|
||||
echo ':aarch64-linux:M::\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\xb7\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\x00\xff\xfe\xff\xff\xff:/run/binfmt/aarch64-linux:' > /proc/sys/fs/binfmt_misc/register
|
||||
echo ':armv6l-linux:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x28\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\x00\xff\xfe\xff\xff\xff:/run/binfmt/arm-linux:' > /proc/sys/fs/binfmt_misc/register
|
||||
echo ':armv7l-linux:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x28\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\x00\xff\xfe\xff\xff\xff:/run/binfmt/arm-linux:' > /proc/sys/fs/binfmt_misc/register
|
||||
'';
|
||||
};
|
||||
|
||||
gh-actions = {
|
||||
on = let
|
||||
paths = [
|
||||
|
|
@ -69,15 +46,6 @@ in {
|
|||
}
|
||||
];
|
||||
};
|
||||
jobs = mkIf (config.id != "ci") {
|
||||
${config.id}.step.architectures = {
|
||||
order = 201;
|
||||
name = "prepare for emulated builds";
|
||||
run = ''
|
||||
sudo $(which archbinfmt)
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
channels = {
|
||||
|
|
|
|||
37
ci/nodes.nix
37
ci/nodes.nix
|
|
@ -11,10 +11,9 @@ with lib; {
|
|||
nixpkgs.args.localSystem = "x86_64-linux";
|
||||
|
||||
ci = {
|
||||
version = "v0.6";
|
||||
version = "v0.7";
|
||||
gh-actions = {
|
||||
enable = true;
|
||||
export = true;
|
||||
};
|
||||
};
|
||||
channels.nixfiles.path = ../.;
|
||||
|
|
@ -25,40 +24,6 @@ with lib; {
|
|||
#extra-sandbox-paths = with channels.cipkgs; map (package: builtins.unsafeDiscardStringContext "${package}?") [bash qemu "/run/binfmt"];
|
||||
};
|
||||
|
||||
gh-actions = {
|
||||
jobs = mkIf (config.id != "ci") {
|
||||
${config.id}.step.architectures = {
|
||||
order = 201;
|
||||
name = "prepare for emulated builds";
|
||||
run = ''
|
||||
sudo $(which archbinfmt)
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
environment.bootstrap = {
|
||||
archbinfmt = let
|
||||
makeQemuWrapper = name: ''
|
||||
mkdir -p /run/binfmt
|
||||
rm -f /run/binfmt/${name}-linux
|
||||
cat > /run/binfmt/${name}-linux << 'EOF'
|
||||
#!${channels.cipkgs.bash}/bin/sh
|
||||
exec -- ${channels.cipkgs.qemu}/bin/qemu-${name} "$@"
|
||||
EOF
|
||||
chmod +x /run/binfmt/${name}-linux
|
||||
'';
|
||||
in
|
||||
channels.cipkgs.writeShellScriptBin "archbinfmt" ''
|
||||
${makeQemuWrapper "aarch64"}
|
||||
${makeQemuWrapper "arm"}
|
||||
echo 'extra-sandbox-paths = ${channels.cipkgs.bash} ${channels.cipkgs.qemu} /run/binfmt' >> /etc/nix/nix.conf
|
||||
echo ':aarch64-linux:M::\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\xb7\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\x00\xff\xfe\xff\xff\xff:/run/binfmt/aarch64-linux:' > /proc/sys/fs/binfmt_misc/register
|
||||
echo ':armv6l-linux:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x28\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\x00\xff\xfe\xff\xff\xff:/run/binfmt/arm-linux:' > /proc/sys/fs/binfmt_misc/register
|
||||
echo ':armv7l-linux:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x28\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\x00\xff\xfe\xff\xff\xff:/run/binfmt/arm-linux:' > /proc/sys/fs/binfmt_misc/register
|
||||
'';
|
||||
};
|
||||
|
||||
jobs = let
|
||||
enabledHosts = ["hakurei" "reimu" "aya" "tei" "mediabox" "ct"];
|
||||
in
|
||||
|
|
|
|||
8
flake.lock
generated
8
flake.lock
generated
|
|
@ -24,16 +24,16 @@
|
|||
"ci": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1702334111,
|
||||
"narHash": "sha256-BLk0GUHGSxW3h35nlRjXzb3tKFC2rq29PLGMNxMtlVc=",
|
||||
"lastModified": 1707782685,
|
||||
"narHash": "sha256-1in0xT0MKHZn/1jrNMUp7rbVCgVj79HF0Fmao1IsTE0=",
|
||||
"owner": "arcnmx",
|
||||
"repo": "ci",
|
||||
"rev": "1176d85875516e5dcff58333feb46f570187c4da",
|
||||
"rev": "fc284b03f16fa9cb82ca93bdef8106866f1d7287",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "arcnmx",
|
||||
"ref": "v0.6",
|
||||
"ref": "v0.7",
|
||||
"repo": "ci",
|
||||
"type": "github"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
url = "github:chessai/nix-std";
|
||||
};
|
||||
ci = {
|
||||
url = "github:arcnmx/ci/v0.6";
|
||||
url = "github:arcnmx/ci/v0.7";
|
||||
flake = false;
|
||||
};
|
||||
flake-compat = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue