瀏覽代碼

new tasks structure

main
Markus Brechtel 6 年之前
父節點
當前提交
d571c6fe44
共有 4 個檔案被更改,包括 62 行新增58 行删除
  1. +42
    -0
      tasks/build.yaml
  2. +0
    -58
      tasks/config.yaml
  3. +11
    -0
      tasks/main.yaml
  4. +9
    -0
      tasks/setup.yaml

+ 42
- 0
tasks/build.yaml 查看文件

@@ -0,0 +1,42 @@
---

- name: lb bootstrap (first build stage)
command: lb bootstrap
args:
chdir: "{{ live_build_directory }}"
register: _lb_bootstrap

- name: lb chroot (second build stage)
command: lb chroot
args:
chdir: "{{ live_build_directory }}"
register: _lb_chroot

- name: lb installer (third build stage)
command: lb installer
args:
chdir: "{{ live_build_directory }}"
register: _lb_installer

- name: lb binary (fourth build stage)
command: lb binary
args:
chdir: "{{ live_build_directory }}"
register: _lb_binary

#- name: lb source (fifth build stage)
# command: lb source
# args:
# chdir: "{{ live_source_directory }}"
# register: _lb_source

#- name: lb build
# command: lb build
# args:
# chdir: "{{ live_build_directory }}"
# register: _lb_build
#
#- name: save build log
# copy:
# content: "{{ _lb_build.stdout }}"
# dest: "{{ live_build_directory }}/build.log"

tasks/main.yml → tasks/config.yaml 查看文件

@@ -1,22 +1,5 @@
---

- setup:
gather_subset: '!all'

- name: install apt packages
apt:
pkg: "{{ item }}"
state: installed
with_items:
- live-build
- memtest86
- memtest86+

- name: debian live-build directory
file:
path: "{{ live_build_directory }}"
state: directory

- name: remove config directory
file:
path: "{{ live_build_directory }}/config"
@@ -66,44 +49,3 @@
template:
src: preseed.cfg.j2
dest: "{{ live_build_directory }}/config/includes.installer/preseed.cfg"

- name: lb bootstrap (first build stage)
command: lb bootstrap
args:
chdir: "{{ live_build_directory }}"
register: _lb_bootstrap

- name: lb chroot (second build stage)
command: lb chroot
args:
chdir: "{{ live_build_directory }}"
register: _lb_chroot

- name: lb installer (third build stage)
command: lb installer
args:
chdir: "{{ live_build_directory }}"
register: _lb_installer

- name: lb binary (fourth build stage)
command: lb binary
args:
chdir: "{{ live_build_directory }}"
register: _lb_binary

#- name: lb source (fifth build stage)
# command: lb source
# args:
# chdir: "{{ live_source_directory }}"
# register: _lb_source

#- name: lb build
# command: lb build
# args:
# chdir: "{{ live_build_directory }}"
# register: _lb_build
#
#- name: save build log
# copy:
# content: "{{ _lb_build.stdout }}"
# dest: "{{ live_build_directory }}/build.log"

+ 11
- 0
tasks/main.yaml 查看文件

@@ -0,0 +1,11 @@
---

- import_tasks: setup.yaml

- name: debian live-build directory
file:
path: "{{ live_build_directory }}"
state: directory

- import_tasks: config.yaml
- import_tasks: build.yaml

+ 9
- 0
tasks/setup.yaml 查看文件

@@ -0,0 +1,9 @@
---
- name: install apt packages
apt:
pkg: "{{ item }}"
state: installed
with_items:
- live-build
- memtest86
- memtest86+

Loading…
取消
儲存