From 5e308d64ad4886b8c5daa235f72b42d40c013ae1 Mon Sep 17 00:00:00 2001 From: Richard Carson Derr Date: Tue, 7 Mar 2023 21:43:50 -0500 Subject: [PATCH] story(rack-blade): implement runtime config (#6) * chore(workflow): fix spelling mistake * feat(rack-blade): implement initial runtime config * feat(rack-blade): boot will now swap runtime config in after booting up --- .github/workflows/main.yml | 6 ++++-- README.md | 2 +- rack-blade/boot.bu | 4 ++++ rack-blade/runtime.bu | 7 +++++++ 4 files changed, 16 insertions(+), 3 deletions(-) create mode 100644 rack-blade/runtime.bu diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 6ce13b86..adc6a978 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -19,11 +19,12 @@ jobs: run: | mkdir dist podman run --rm -v ./rack-blade/boot.bu:/config.bu:z quay.io/coreos/butane:release --pretty --strict /config.bu > ./dist/rack-blade-boot.ign + podman run --rm -v ./rack-blade/runtime.bu:/config.bu:z quay.io/coreos/butane:release --pretty --strict /config.bu > ./dist/rack-blade-runtime.ign - name: Embed ignition files in ISO images run: | iso=$(podman run --security-opt label=disable --pull=always --rm -v .:/data -w /data quay.io/coreos/coreos-installer:release download -f iso 2>/dev/null) - podman run --security-opt label=disable --pull=always --rm -v .:/data -w /data quay.io/coreos/coreos-installer:release iso customize --live-ignition ./dist/rack-blade-boot.ign -o ./dist/rack-blade.iso $iso + podman run --security-opt label=disable --pull=always --rm -v .:/data -w /data quay.io/coreos/coreos-installer:release iso customize --live-ignition ./dist/rack-blade-boot.ign -o ./dist/rack-blade-boot.iso $iso - name: Release uses: softprops/action-gh-release@v1 @@ -31,4 +32,5 @@ jobs: with: files: | dist/rack-blade-boot.ign - dist/rack-blade.iso \ No newline at end of file + dist/rack-blade-runtime.ign + dist/rack-blade-boot.iso \ No newline at end of file diff --git a/README.md b/README.md index 35d4ef03..87b210d5 100644 --- a/README.md +++ b/README.md @@ -1 +1 @@ -# Infrastructure as Code Monorepo \ No newline at end of file +# My Infrastructure as Code Monorepo \ No newline at end of file diff --git a/rack-blade/boot.bu b/rack-blade/boot.bu index 399700ea..c1ac9e89 100644 --- a/rack-blade/boot.bu +++ b/rack-blade/boot.bu @@ -1,5 +1,9 @@ variant: fcos version: 1.4.0 +ignition: + config: + replace: + source: https://github.com/Zaba505/infra/releases/latest/download/rack-blade-runtime.ign passwd: users: - name: core diff --git a/rack-blade/runtime.bu b/rack-blade/runtime.bu new file mode 100644 index 00000000..c142f32d --- /dev/null +++ b/rack-blade/runtime.bu @@ -0,0 +1,7 @@ +variant: fcos +version: 1.4.0 +passwd: + users: + - name: core + ssh_authorized_keys: + - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIECro1+siPNnv4iA078ov0OJEP6+0KgouufjB6F+SXr0 cakub6@gmx.com \ No newline at end of file