Merge "Rework: Move nailgun timeout patch to postinstall"
[armband.git] / patches / opnfv-fuel / 000098-FIXME-Build-local-mirrors-for-stable-mitaka.patch
1 From: Michal Skalski <mskalski@mirantis.com>
2 Date: Wed, 8 Jun 2016 00:54:57 +0200
3 Subject: [PATCH] Build local mirrors for stable/mitaka
4
5 Still in verification.
6
7 Change-Id: I3128652aeb87cb2cfaa91ded1b8d9ebeeb70d33b
8 Signed-off-by: Michal Skalski <mskalski@mirantis.com>
9 ---
10  build/Makefile                                     |    4 ++
11  build/bootstrap_admin_node.sh.patch                |   22 ++++++++++++
12  build/f_isoroot/Makefile                           |    4 +-
13  build/f_isoroot/f_odlpluginbuild/Makefile          |    1 +
14  build/f_isoroot/f_repobuild/Makefile               |    2 +-
15  .../f_isoroot/f_repobuild/fuel_bootstrap_cli.yaml  |   36 +++++++++++---------
16  6 files changed, 50 insertions(+), 19 deletions(-)
17
18 diff --git a/build/Makefile b/build/Makefile
19 index fdfb239..956183c 100644
20 --- a/build/Makefile
21 +++ b/build/Makefile
22 @@ -24,6 +24,10 @@ export ISOCACHE = $(shell pwd)/$(shell basename $(ISOSRC))
23  export PRODNO = "OPNFV_FUEL"
24  export REVSTATE = "P0000"
25  export USER ?= $(shell whoami)
26 +export BUILD_DATE = $(shell date --utc +%Y-%m-%d:%H:%M)
27 +export OPNFV_GIT_SHA = $(shell git rev-parse HEAD)
28 +# Store in /etc/fuel_build_id on fuel master
29 +export BUILD_ID := $(PRODNO)_$(BUILD_DATE)_$(OPNFV_GIT_SHA)
30  
31  ifdef BUILD_FUEL_PLUGINS
32  $(warning Overriding plugin build selection to $(BUILD_FUEL_PLUGINS))
33 diff --git a/build/bootstrap_admin_node.sh.patch b/build/bootstrap_admin_node.sh.patch
34 index aeef3f7..e137b74 100644
35 --- a/build/bootstrap_admin_node.sh.patch
36 +++ b/build/bootstrap_admin_node.sh.patch
37 @@ -34,6 +34,28 @@
38      # Give user 15 seconds to enter fuelmenu or else continue
39      echo
40  ***************
41 +*** 360,368 ****
42 +    fi
43 +  fi
44 +
45 +  # Enable online base MOS repos (security, updates) if we run an ISO installation
46 +! [ -f /etc/fuel_build_id ] && \
47 +!   yum-config-manager --enable mos${FUEL_RELEASE}-security mos${FUEL_RELEASE}-updates --save
48 +
49 +  if [ ! -f "${ASTUTE_YAML}" ]; then
50 +    echo ${fuelmenu_fail_message}
51 +--- 360,369 ----
52 +    fi
53 +  fi
54 +
55 ++ # OPNFV: Disabled to speedup installation in offline env.
56 +  # Enable online base MOS repos (security, updates) if we run an ISO installation
57 +! #[ -f /etc/fuel_build_id ] && \
58 +! #  yum-config-manager --enable mos${FUEL_RELEASE}-security mos${FUEL_RELEASE}-updates --save
59 +
60 +  if [ ! -f "${ASTUTE_YAML}" ]; then
61 +    echo ${fuelmenu_fail_message}
62 +***************
63  *** 374,382 ****
64    [ ! -f /etc/fuel_build_id ] && \
65      sed -i "s|127.0.0.1:8080/ubuntu/x86_64|mirror.fuel-infra.org/mos-repos/ubuntu/${FUEL_RELEASE}|g" "${ASTUTE_YAML}"
66 diff --git a/build/f_isoroot/Makefile b/build/f_isoroot/Makefile
67 index 17ebef3..ed54e70 100644
68 --- a/build/f_isoroot/Makefile
69 +++ b/build/f_isoroot/Makefile
70 @@ -23,10 +23,10 @@ export PLUGINS
71  ifdef BUILD_FUEL_PLUGINS
72  export BUILD_FUEL_PLUGINS
73  #SUBDIRS = f_kscfg f_bootstrap f_isolinux f_repobuild $(BUILD_FUEL_PLUGINS)
74 -SUBDIRS = f_kscfg f_bootstrap f_isolinux $(BUILD_FUEL_PLUGINS)
75 +SUBDIRS = f_kscfg f_bootstrap f_isolinux f_repobuild $(BUILD_FUEL_PLUGINS)
76  $(warning Overriding plugin build selection to $(BUILD_FUEL_PLUGINS))
77  else
78 -SUBDIRS = f_kscfg f_bootstrap f_isolinux $(PLUGINS)
79 +SUBDIRS = f_kscfg f_bootstrap f_isolinux f_repobuild $(PLUGINS)
80  endif
81  SUBCLEAN = $(addsuffix .clean,$(SUBDIRS))
82  
83 diff --git a/build/f_isoroot/f_odlpluginbuild/Makefile b/build/f_isoroot/f_odlpluginbuild/Makefile
84 index efea0f5..c5978de 100644
85 --- a/build/f_isoroot/f_odlpluginbuild/Makefile
86 +++ b/build/f_isoroot/f_odlpluginbuild/Makefile
87 @@ -18,6 +18,7 @@ all: .odlbuild
88  clean:
89         @rm -f .odlbuild ../release/opnfv/opendaylight*.rpm opendaylight*.rpm
90         @rm -f $(BUILD_BASE)/gitinfo_odlplugin.txt gitinfo_odlplugin.txt
91 +       @rm -rf fuel-plugins
92  
93  .PHONY: release
94  release:.odlbuild
95 diff --git a/build/f_isoroot/f_repobuild/Makefile b/build/f_isoroot/f_repobuild/Makefile
96 index e95dbf2..5277218 100644
97 --- a/build/f_isoroot/f_repobuild/Makefile
98 +++ b/build/f_isoroot/f_repobuild/Makefile
99 @@ -47,7 +47,7 @@ nailgun:
100  
101  .PHONY: clean
102  clean:
103 -       @rm -rf ../release/opnfv/nailgun nailgun fuel-mirror
104 +       @rm -rf ../release/opnfv/nailgun nailgun fuel-mirror opnfv-config.yaml ubuntu.yaml
105  
106  .PHONY: release
107  release:nailgun
108 diff --git a/build/f_isoroot/f_repobuild/fuel_bootstrap_cli.yaml b/build/f_isoroot/f_repobuild/fuel_bootstrap_cli.yaml
109 index aa12c45..d8fab97 100644
110 --- a/build/f_isoroot/f_repobuild/fuel_bootstrap_cli.yaml
111 +++ b/build/f_isoroot/f_repobuild/fuel_bootstrap_cli.yaml
112 @@ -1,33 +1,37 @@
113  ---
114    root_ssh_authorized_file: /root/.ssh/id_rsa.pub
115    extend_kopts: "biosdevname=0 net.ifnames=1 debug ignore_loglevel log_buf_len=10M print_fatal_signals=1 LOGLEVEL=8"
116 +  ubuntu_release: trusty
117    extra_dirs:
118      - /usr/share/fuel_bootstrap_cli/files/trusty
119    output_dir: /tmp/
120    kernel_flavor: linux-image-generic-lts-trusty
121    packages:
122 -    - vim
123 +    - fuel-agent
124 +    - hwloc
125 +    - hpsa-dkms
126 +    - i40e-dkms
127 +    - linux-firmware
128 +    - linux-firmware-nonfree
129 +    - linux-headers-generic
130 +    - live-boot
131 +    - live-boot-initramfs-tools
132      - mc
133 -    - openssh-client
134 -    - openssh-server
135 -    - ntp
136      - mcollective
137 +    - msmtp-mta
138 +    - multipath-tools
139 +    - multipath-tools-boot
140      - nailgun-agent
141      - nailgun-mcagents
142      - network-checker
143 -    - fuel-agent
144 +    - ntp
145 +    - openssh-client
146 +    - openssh-server
147 +    - squashfs-tools
148      - ubuntu-minimal
149 -    - live-boot
150 -    - live-boot-initramfs-tools
151 +    - vim
152      - wget
153 -    - linux-firmware
154 -    - linux-firmware-nonfree
155 -    - linux-headers-generic
156 -    - hpsa-dkms
157 -    - i40e-dkms
158      - xz-utils
159 -    - squashfs-tools
160 -    - msmtp-mta
161    bootstrap_images_dir: /var/www/nailgun/bootstraps
162    active_bootstrap_symlink: /var/www/nailgun/bootstraps/active_bootstrap
163    flavor: ubuntu
164 @@ -56,8 +60,8 @@
165        section: "main restricted"
166        uri: "http://127.0.0.1:8080/ubuntu/x86_64"
167        priority: 1050
168 -      suite: mos8.0
169 +      suite: mos9.0
170        type: deb
171 -  skip_default_img_build: true
172 +  skip_default_img_build: false
173    direct_repo_addresses:
174      - "127.0.0.1"