From d759f2d995f249f24eaf854476454e6fbf25792a Mon Sep 17 00:00:00 2001 From: Pierre Neyron <pierre.neyron@imag.fr> Date: Fri, 19 Apr 2019 18:26:43 +0200 Subject: [PATCH] Drop unwanted files --- .../debian9-x64-custom.yaml~ | 74 ------------------- .../steps/bootstrap/prepare_appliance.yaml~ | 53 ------------- 2 files changed, 127 deletions(-) delete mode 100644 kameleon/kameleon-recipes/from_kadeploy_environment/debian9-x64-custom.yaml~ delete mode 100644 kameleon/kameleon-recipes/steps/bootstrap/prepare_appliance.yaml~ diff --git a/kameleon/kameleon-recipes/from_kadeploy_environment/debian9-x64-custom.yaml~ b/kameleon/kameleon-recipes/from_kadeploy_environment/debian9-x64-custom.yaml~ deleted file mode 100644 index b7dffdb..0000000 --- a/kameleon/kameleon-recipes/from_kadeploy_environment/debian9-x64-custom.yaml~ +++ /dev/null @@ -1,74 +0,0 @@ -#============================================================================== -# vim: softtabstop=2 shiftwidth=2 expandtab fenc=utf-8 cc=81 tw=80 -#============================================================================== -# -# DESCRIPTION: base recipe for a customization of a Grid'5000 environment -# -#============================================================================== ---- -extend: ../steps/backend/$${backend}.yaml - -# Loads some helpful aliases (this files are located in steps/aliases/ directory) -aliases: defaults.yaml - -# Custom shell environement (this files are located in steps/env/ directory) -env: - - bashrc - - functions.sh - -# Global variables use by Kameleon engine and the steps -global: - # Architecture for the target system - arch: x86_64 - # Distribution - distrib: debian - release: 9 - # Kadeploy environment - kadeploy_environment_import_name: "debian9-x64-min" - kadeploy_environment_import_user: "deploy" - kadeploy_environment_import_version: "" - kadeploy_frontend: "frontend" - kadeploy_environment_export_name: "$${kameleon_recipe_name}" - kadeploy_environment_export_format: "tar.gz" - kadeploy_environment_export_description: "Customized $${kadeploy_environment_import_name}" - kadeploy_environment_export_dir: "$HOME/public/" - kadeploy_environment_export_baseurl: "local://$HOME/public/" - - # output appliance options - filesystem_type: ext4 - image_size: 10G - image_disk: $${kameleon_cwd}/base_$${kameleon_recipe_name} - # Allowed formats are: tar.gz, tar.bz2, tar.xz, tar.lzo, qcow, qcow2, qed, vdi, raw, vmdk - appliance_formats: "$${kadeploy_environment_export_format}" - appliance_tar_compression_level: "9" - appliance_filename: "$${kameleon_cwd}/$${kameleon_recipe_name}" - appliance_tar_excludes: >- - ./etc/fstab ./root/.bash_history ./root/kameleon_workdir ./root/.ssh - ./var/tmp/* ./tmp/* ./var/log/* ./dev/* ./proc/* ./run/* - ./sys/* - # rootfs options - rootfs: $${kameleon_cwd}/rootfs - - # kernel boot parameters: use legacy network interfaces - kernel_args: "quiet net.ifnames=0 biosdevname=0" - - ssh_config_file: $${kameleon_cwd}/ssh_config - local_ip: 10.0.2.2 - - ## Select backend for in context isolation - backend: qemu - - ## System variables. Required by kameleon engine - # Include specific steps - include_steps: - - $${distrib}/$${release} - - $${distrib} -bootstrap: - - "@base" - -setup: - # Add steps here - -export: - - "@base" - - create_kadeploy_environment diff --git a/kameleon/kameleon-recipes/steps/bootstrap/prepare_appliance.yaml~ b/kameleon/kameleon-recipes/steps/bootstrap/prepare_appliance.yaml~ deleted file mode 100644 index 13c62bc..0000000 --- a/kameleon/kameleon-recipes/steps/bootstrap/prepare_appliance.yaml~ +++ /dev/null @@ -1,53 +0,0 @@ -- insecure_ssh_key: $${kameleon_cwd}/insecure_ssh_key -- enable_workaround_login_delay: false - -- generate_ssh_keys: - - check_cmd_local: ssh-keygen - - exec_local: echo -e 'y\n' | ssh-keygen -q -t rsa -b 4096 -f $${insecure_ssh_key} -N '' - - exec_local: cat $${insecure_ssh_key} - -- inject_ssh_private_key: - - check_cmd_local: virt-customize - - exec_local: | - virt-customize \ - -a $${image_disk}.$${image_format} \ - --run-command 'mkdir -p /root/.ssh' \ - --upload $${insecure_ssh_key}.pub:/root/.ssh/.kameleon_authorized_keys \ - --run-command 'touch /root/.ssh/authorized_keys' \ - --run-command 'cp /root/.ssh/authorized_keys /root/.ssh/authorized_keys.bak' \ - --run-command 'cat /root/.ssh/.kameleon_authorized_keys >> /root/.ssh/authorized_keys' \ - --run-command 'chmod 700 /root/.ssh' \ - --run-command 'chmod -R go-rw /root/.ssh' \ - --run-command 'chown -R root:root /root/.ssh' - - on_export_init: - - exec_local: | - virt-customize \ - -a $${image_disk}.$${image_format} \ - --run-command 'mv /root/.ssh/authorized_keys.bak /root/.ssh/authorized_keys' \ - --delete /root/.ssh/.kameleon_authorized_keys - -- add_insecure_key_to_ssh_config: - - on_checkpoint: redo - - exec_local: | - cat <<EOF >> $${ssh_config_file} - IdentityFile $${insecure_ssh_key} - EOF - -- workaround_login_delay_due_to_ldap_and_dns: - - test: - - exec_local: test "$${enable_workaround_login_delay}" = "true" - - exec_local: | - virt-customize \ - -a $${image_disk}.$${image_format} \ - --run-command 'mv /etc/nslcd.conf /etc/nslcd.conf.orig-g5k' \ - --run-command 'sed -i.orig-g5k "s/ ldap//" /etc/nsswitch.conf' \ - --run-command 'echo > /etc/resolv.conf' - - exec_local: echo "Workaround is not enabled" - - on_setup_clean: - - test: - - exec_local: test "$${enable_workaround_login_delay}" = "true" - - exec_local: | - virt-customize \ - -a $${image_disk}.$${image_format} \ - --run-command 'mv /etc/nslcd.conf.orig-g5k /etc/nslcd.conf' \ - --run-command 'mv /etc/nsswitch.conf.orig-g5k /etc/nsswitch.conf' -- GitLab