From 1afcc59c950565ff29f85d88de727304665e0f01 Mon Sep 17 00:00:00 2001 From: Denis 'GNUtoo' Carikli Date: Sat, 7 Oct 2023 02:01:32 +0200 Subject: [PATCH] gnutoo-trisquel-installer: Add minimal FAI config Signed-off-by: Denis 'GNUtoo' Carikli --- gnutoo-trisquel-installer/README | 14 +++++++++++ .../config/class/50-host-classes | 23 +++++++++++++++++++ .../config/files/etc/cron.d/fai/FAIBASE | 1 + .../config/files/etc/fai/fai.conf/FAIBASE | 17 ++++++++++++++ .../config/package_config/FAIBASE | 18 +++++++++++++++ .../config/scripts/FAIBASE/01-files | 19 +++++++++++++++ 6 files changed, 92 insertions(+) create mode 100644 gnutoo-trisquel-installer/README create mode 100755 gnutoo-trisquel-installer/config/class/50-host-classes create mode 100644 gnutoo-trisquel-installer/config/files/etc/cron.d/fai/FAIBASE create mode 100644 gnutoo-trisquel-installer/config/files/etc/fai/fai.conf/FAIBASE create mode 100644 gnutoo-trisquel-installer/config/package_config/FAIBASE create mode 100755 gnutoo-trisquel-installer/config/scripts/FAIBASE/01-files diff --git a/gnutoo-trisquel-installer/README b/gnutoo-trisquel-installer/README new file mode 100644 index 0000000..4aa9de8 --- /dev/null +++ b/gnutoo-trisquel-installer/README @@ -0,0 +1,14 @@ +License +======= +This project is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 3 of the License, or +(at your option) any later version. + +This project is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this project. If not, see . diff --git a/gnutoo-trisquel-installer/config/class/50-host-classes b/gnutoo-trisquel-installer/config/class/50-host-classes new file mode 100755 index 0000000..0818f15 --- /dev/null +++ b/gnutoo-trisquel-installer/config/class/50-host-classes @@ -0,0 +1,23 @@ +#!/bin/sh +# +# Copyright (C) 2023 Denis 'GNUtoo' Carikli +# +# This project is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This project is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this project. If not, see . + +case $HOSTNAME in + *) + echo "FAIBASE" ;; +esac + + diff --git a/gnutoo-trisquel-installer/config/files/etc/cron.d/fai/FAIBASE b/gnutoo-trisquel-installer/config/files/etc/cron.d/fai/FAIBASE new file mode 100644 index 0000000..9c780b4 --- /dev/null +++ b/gnutoo-trisquel-installer/config/files/etc/cron.d/fai/FAIBASE @@ -0,0 +1 @@ +40 * * * * root /usr/sbin/fai -vNu $HOSTNAME softupdate diff --git a/gnutoo-trisquel-installer/config/files/etc/fai/fai.conf/FAIBASE b/gnutoo-trisquel-installer/config/files/etc/fai/fai.conf/FAIBASE new file mode 100644 index 0000000..8676608 --- /dev/null +++ b/gnutoo-trisquel-installer/config/files/etc/fai/fai.conf/FAIBASE @@ -0,0 +1,17 @@ +# +# Copyright (C) 2023 Denis 'GNUtoo' Carikli +# +# This project is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This project is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this project. If not, see . + +FAI_CONFIG_SRC=file:///root/config diff --git a/gnutoo-trisquel-installer/config/package_config/FAIBASE b/gnutoo-trisquel-installer/config/package_config/FAIBASE new file mode 100644 index 0000000..3de3803 --- /dev/null +++ b/gnutoo-trisquel-installer/config/package_config/FAIBASE @@ -0,0 +1,18 @@ +# +# Copyright (C) 2023 Denis 'GNUtoo' Carikli +# +# This project is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This project is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this project. If not, see . + +PACKAGES install +guix diff --git a/gnutoo-trisquel-installer/config/scripts/FAIBASE/01-files b/gnutoo-trisquel-installer/config/scripts/FAIBASE/01-files new file mode 100755 index 0000000..343111a --- /dev/null +++ b/gnutoo-trisquel-installer/config/scripts/FAIBASE/01-files @@ -0,0 +1,19 @@ +#!/bin/sh +# +# Copyright (C) 2023 Denis 'GNUtoo' Carikli +# +# This project is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This project is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this project. If not, see . + +fcopy -iM /etc/fai/fai.conf +fcopy -i -m root,root,0755 /etc/cron.d/fai