From 3bf48fb977b123f313c7bc817a7a8c3d5453e403 Mon Sep 17 00:00:00 2001 From: Denis 'GNUtoo' Carikli Date: Thu, 21 Sep 2023 12:46:35 +0200 Subject: [PATCH] Add default id_ed25519.pub and signing-key.pub This makes it easier to deploy the VM to the Libre En Communs infrastructure as it doesn't require to also copy these files to the VM producing the image. Signed-off-by: Denis 'GNUtoo' Carikli --- Makefile.am | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/Makefile.am b/Makefile.am index cae800b..a5288f8 100644 --- a/Makefile.am +++ b/Makefile.am @@ -34,7 +34,7 @@ guix-commit.txt: Makefile %.html: %.html.tmpl guix-commit.txt Makefile sed 's#DOMAIN#$(DOMAIN)#g' $< > $@ -%.scm: %.scm.tmpl guix-commit.txt Makefile +%.scm: %.scm.tmpl guix-commit.txt id_ed25519.pub Makefile signing-key.pub sed \ "s#DOMAIN#$(DOMAIN)#g ; \ s#ENABLE_WIREGUARD#$(ENABLE_WIREGUARD)#g ; \ @@ -55,6 +55,19 @@ guix-commit.txt: Makefile s#VM_SSH_ADDRESS#$(VM_SSH_ADDRESS)#g" $< > $@ chmod +x $@ +# Generate default key. Can be changed by replacing id_ed25519.pub. +id_ed25519.pub: + printf "ssh-ed25519 %s %s" \ + 'AAAAC3NzaC1lZDI1NTE5AAAAIH2feuEj4asx0ImCG+cuiPv2WdKF6vMI+cJtZyG9cwUQ' \ + 'gnutoo@primary_laptop' + > $@ + +# Generate default key. Can be changed by replacing signing-key.pub. +signing-key.pub: + printf '(public-key (ecc (curve Ed25519) (q #%s#)))\n' \ + '3A7E1F41E2D5784CFCABB39CB73F99E727D4A5C1ECA79D873587D63D093CC4B5' \ + >$@ + IMAGE_SOURCE = \ first-boot.sh \ guix-commit.txt \