From 6d7159854933a8a433425968cfc44486f5ea7ad4 Mon Sep 17 00:00:00 2001 From: Jonathan Bauer Date: Tue, 21 Aug 2018 15:56:22 +0200 Subject: [slx-builder] add missing files --- slx-builder/tasks/build.yml | 20 ++++++++++++++++++++ slx-builder/tasks/install.yml | 28 ++++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 slx-builder/tasks/build.yml create mode 100644 slx-builder/tasks/install.yml (limited to 'slx-builder') diff --git a/slx-builder/tasks/build.yml b/slx-builder/tasks/build.yml new file mode 100644 index 0000000..aae94c4 --- /dev/null +++ b/slx-builder/tasks/build.yml @@ -0,0 +1,20 @@ +--- +- name: OpenSLX dracut | Build initramfs + shell: "{{ builder_path }} -s -d -p {{ builder_target }} - --add 'kexec-reboot'" + args: + creates: "{{ builder_target }}" + +- name: OpenSLX dracut | Retrieve initramfs and kernel (+ hack for weird /@ prefix of BOOT_IMAGE) + fetch: + src: "{{ item }}" + dest: "{{ playbook_dir }}/boot_files/" + fail_on_missing: yes + flat: yes + with_items: + - "{{ builder_target }}" + - "{{ ansible_cmdline.BOOT_IMAGE | regex_replace('^/@(/boot/.*)+$', '\\1') }}" + +- name: OpenSLX dracut | Cleanup + file: + path: "{{ builder_path | dirname }}" + state: absent diff --git a/slx-builder/tasks/install.yml b/slx-builder/tasks/install.yml new file mode 100644 index 0000000..c7393be --- /dev/null +++ b/slx-builder/tasks/install.yml @@ -0,0 +1,28 @@ +--- +- include: tasks/distro.yml + +- name: OpenSLX dracut | Install dependencies + package: + name: "{{ item }}" + state: present + with_items: "{{ pkgnames }}" + +- name: OpenSLX dracut | Create download destination directory + file: + path: "{{ builder_path | dirname }}" + state: directory + +- name: OpenSLX dracut | Download bootstrap script + get_url: + url: "{{ builder_url }}" + checksum: "{{ builder_checksum }}" + dest: "{{ builder_path }}" + mode: 0550 + +- name: OpenSLX dracut | Initialize repository + shell: "{{ builder_path }} --init" + args: + creates: "${{ builder_path | dirname }}/dracut/dracut.sh" + +- include: tasks/dnbd3-fixes.yml + -- cgit v1.2.3-55-g7522