Merge "Temporary fix for PXE booting from the wrong NIC"
[fuel.git] / build / bootstrap_admin_node.sh.patch
1 *** bootstrap_admin_node.sh.orig        Mon May 30 06:31:38 2016
2 --- bootstrap_admin_node.sh     Mon May 30 06:35:11 2016
3 ***************
4 *** 339,346 ****
5   set +x
6   echo "Done!"
7   
8   if [[ "$showmenu" == "yes" || "$showmenu" == "YES" ]]; then
9 !   fuelmenu || fail
10   else
11     # Give user 15 seconds to enter fuelmenu or else continue
12     echo
13 --- 339,360 ----
14   set +x
15   echo "Done!"
16   
17 + ### OPNFV addition BEGIN
18 + shopt -s nullglob
19 + for script in /opt/opnfv/bootstrap/pre.d/*.sh
20 + do
21 +   echo "Pre script: $script" >> /root/pre.log 2>&1
22 +   $script >> /root/pre.log 2>&1
23 + done
24 + shopt -u nullglob
25 + ### OPNFV addition END
26
27 + # Enable sshd
28 + systemctl enable sshd
29 + systemctl start sshd
30
31   if [[ "$showmenu" == "yes" || "$showmenu" == "YES" ]]; then
32 !   fuelmenu
33   else
34     # Give user 15 seconds to enter fuelmenu or else continue
35     echo
36 ***************
37 *** 374,382 ****
38   [ ! -f /etc/fuel_build_id ] && \
39     sed -i "s|127.0.0.1:8080/ubuntu/x86_64|mirror.fuel-infra.org/mos-repos/ubuntu/${FUEL_RELEASE}|g" "${ASTUTE_YAML}"
40   
41 ! # Enable sshd
42 ! systemctl enable sshd
43 ! systemctl start sshd
44   
45   # Enable iptables
46   systemctl enable iptables.service
47 --- 388,394 ----
48   [ ! -f /etc/fuel_build_id ] && \
49     sed -i "s|127.0.0.1:8080/ubuntu/x86_64|mirror.fuel-infra.org/mos-repos/ubuntu/${FUEL_RELEASE}|g" "${ASTUTE_YAML}"
50   
51 ! systemctl reload sshd
52   
53   # Enable iptables
54   systemctl enable iptables.service
55 ***************
56 *** 529,534 ****
57 --- 541,556 ----
58   
59   bash /etc/rc.local
60   
61 + ### OPNFV addition BEGIN
62 + shopt -s nullglob
63 + for script in /opt/opnfv/bootstrap/post.d/*.sh
64 + do
65 +   echo "Post script: $script" >> /root/post.log 2>&1
66 +   $script >> /root/post.log 2>&1
67 + done
68 + shopt -u nullglob
69 + ### OPNFV addition END
70
71   if [ "`get_bootstrap_skip`" = "False" ]; then
72     build_ubuntu_bootstrap bs_status || true
73   else