Browse Source

Merge "Fix building ironic bootstrap"

Jenkins 2 years ago
parent
commit
0e307b2693
1 changed files with 16 additions and 16 deletions
  1. 16
    16
      deployment/puppet/osnailyfacter/manifests/provision/build_image.pp

+ 16
- 16
deployment/puppet/osnailyfacter/manifests/provision/build_image.pp View File

@@ -9,7 +9,9 @@ class osnailyfacter::provision::build_image(
9 9
   }
10 10
   $cluster_id = $data['cluster']['id']
11 11
 
12
-  if $data['ironic']['enabled'] == 'true' {
12
+  if $data['ironic']['enabled'] == true {
13
+    # TODO(vsaienko): Use the same system packages for fuel image and ironic bootstrap, but exclude
14
+    # not needed for ironic like nailgun-agent, etc...
13 15
     $ironic_packages = [
14 16
       'openssh-server',
15 17
       'ntp',
@@ -21,9 +23,7 @@ class osnailyfacter::provision::build_image(
21 23
       'squashfs-tools',
22 24
       'linux-firmware',
23 25
       'msmtp-mta',
24
-      'hpsa-dkms',
25 26
       'i40e-dkms',
26
-      'linux-firmware-nonfree',
27 27
       'xz-utils',
28 28
       'linux-headers-generic',
29 29
     ]
@@ -35,25 +35,25 @@ class osnailyfacter::provision::build_image(
35 35
     $out_dir = "/var/www/nailgun/bootstrap/ironic/${cluster_id}/"
36 36
     $out_params = "--output-dir ${out_dir}"
37 37
 
38
-    $extra_params = "--extra-dir /usr/share/ironic-fa-bootstrap-configs/ --no-compress --no-default-extra-dirs --no-default-packages"
39
-    $log_params = '--log-file /var/log/fuel-ironic-bootstrap-image-build.log'
38
+    $ironic_extra_params = "--extra-dir /usr/share/ironic-fa-bootstrap-configs/ --no-compress --no-default-extra-dirs --no-default-packages"
39
+    $ironic_log_params = '--log-file /var/log/fuel-ironic-bootstrap-image-build.log'
40 40
 
41 41
     exec { 'generate_image_with_ironic':
42
-      command => "fuel-bootstrap build ${package_list} ${ssh_params} ${out_params} ${extra_params} ${log_params}",
42
+      command => "fuel-bootstrap build ${package_list} ${ssh_params} ${out_params} ${ironic_extra_params} ${ironic_log_params}",
43 43
       path    => ['/bin', '/usr/bin'],
44
+      timeout => 1800,
44 45
       unless  => "test -e /var/www/nailgun/bootstrap/ironic/${cluster_id}/vmlinuz",
45 46
     }
46 47
 
47
-  } else {
48
-    $build_dir = '--image_build_dir /var/lib/fuel/ibp'
49
-    $log_params = "--log-file /var/log/fuel-agent-env-${cluster_id}.log"
50
-    $extra_params = '--data_driver nailgun_build_image'
48
+  }
51 49
 
52
-    exec { 'generate_image_with_fuel':
53
-      command => "fa_build_image ${build_dir} ${log_params} ${extra_params} --input_data_file ${data_file}",
54
-      path    => ['/bin', '/usr/bin'],
55
-      timeout => 1800,
56
-      unless  => "test -e /var/www/nailgun/bootstrap/ironic/${cluster_id}/vmlinuz",
57
-    }
50
+  $build_dir = '--image_build_dir /var/lib/fuel/ibp'
51
+  $log_params = "--log-file /var/log/fuel-agent-env-${cluster_id}.log"
52
+  $extra_params = '--data_driver nailgun_build_image'
53
+
54
+  exec { 'generate_image_with_fuel':
55
+    command => "fa_build_image ${build_dir} ${log_params} ${extra_params} --input_data_file ${data_file}",
56
+    path    => ['/bin', '/usr/bin'],
57
+    timeout => 1800,
58 58
   }
59 59
 }

Loading…
Cancel
Save