33This repo contains tools for creating BOSH stemcells. A stemcell is a bootable
44disk image that is used as a template by a BOSH Director to create VMs.
55
6+ This branch builds stemcells for ** Ubuntu 26.04 LTS (Resolute)** . For other
7+ Ubuntu releases, switch to the appropriate branch (for example ` ubuntu-noble `
8+ for 24.04).
9+
610## Quick Start: Building a Stemcell Locally
711
812``` bash
9- export short_name=" noble "
13+ export short_name=" resolute "
1014
1115git clone git@github.com:cloudfoundry/bosh-linux-stemcell-builder.git
1216cd bosh-linux-stemcell-builder
1317git checkout ubuntu-${short_name}
1418mkdir -p tmp
1519docker build \
1620 --platform linux/amd64 \
17- --build-arg SYFT_VERSION=v1.42.3 \
21+ --build-arg BASE_IMAGE=" ubuntu:${short_name} " \
22+ --build-arg META4_CLI_URL=" https://github.com/dpb587/metalink/releases/download/v0.5.0/meta4-0.5.0-linux-amd64" \
23+ --build-arg SYFT_CLI_URL=" https://github.com/anchore/syft/releases/download/v1.42.3/syft_1.42.3_linux_amd64.tar.gz" \
24+ --build-arg YQ_CLI_URL=" https://github.com/mikefarah/yq/releases/download/v4.52.5/yq_linux_amd64" \
25+ --build-arg RUBY_INSTALL_URL=" https://github.com/postmodern/ruby-install/releases/download/v0.10.2/ruby-install-0.10.2.tar.gz" \
26+ --build-arg RUBY_VERSION=" $( cat .ruby-version) " \
27+ --build-arg GEM_HOME=" /usr/local/bundle" \
28+ --build-arg OVF_TOOL_INSTALLER=" VMware-ovftool-4.4.3-18663434-lin.x86_64.bundle" \
29+ --build-arg OVF_TOOL_INSTALLER_SHA1=" 6c24e473be49c961cfc3bb16774b52b48e822991" \
1830 -t bosh/os-image-stemcell-builder:${short_name} \
1931 ci/docker/os-image-stemcell-builder/
2032docker run \
2133 --platform linux/amd64 \
2234 --privileged \
2335 -v " $( pwd) :/opt/bosh" \
2436 --workdir /opt/bosh \
25- --user=1000:1000 \
37+ --user=" $( id -u ) : $( id -g ) " \
2638 -it \
2739 bosh/os-image-stemcell-builder:${short_name}
2840
2941# You're now in the Docker container
42+ export short_name=" resolute"
43+
3044ulimit -n 16384 # only necessary if your host is Fedora
3145gem install bundler
3246bundle install
3347
3448 # build OS image
35- bundle exec rake stemcell:build_os_image[ubuntu,${short_name} ,${PWD} /tmp/ubuntu_base_image .tgz]
49+ bundle exec rake stemcell:build_os_image[ubuntu,${short_name} ,${PWD} /tmp/ubuntu_base_image_ ${short_name} .tgz]
3650
3751 # build vSphere stemcell
38- bundle exec rake stemcell:build[vsphere,esxi,ubuntu,${short_name} ,${PWD} /tmp/ubuntu_base_image.tgz]
52+ bundle exec rake stemcell:build[vsphere,esxi,ubuntu,${short_name} ,${PWD} /tmp/ubuntu_base_image_${short_name} .tgz,9.000]
53+
54+ # build warden (BOSH Lite) stemcell
55+ bundle exec rake stemcell:build[warden,warden,ubuntu,${short_name} ,${PWD} /tmp/ubuntu_base_image_${short_name} .tgz,9.000]
3956```
4057
4158When building a vSphere stemcell, you must download ` VMware-ovftool-*.bundle `
@@ -56,7 +73,7 @@ installed in the operating system or when making changes to the configuration
5673of those packages.
5774
5875``` bash
59- export short_name=" noble "
76+ export short_name=" resolute "
6077
6178bundle exec rake stemcell:build_os_image[ubuntu,${short_name} ,${PWD} /tmp/ubuntu_base_image.tgz]
6279```
@@ -78,7 +95,7 @@ The arguments to the `stemcell:build_os_image` rake task follow:
7895Rebuild the stemcell when you are making and testing BOSH-specific changes such as a new BOSH agent.
7996
8097``` bash
81- export short_name=" noble "
98+ export short_name=" resolute "
8299export build_number=" 0.0.8"
83100
84101bundle exec rake stemcell:build[vsphere,esxi,ubuntu,${short_name} ,${PWD} /tmp/ubuntu_base_image.tgz,${build_number} ]
@@ -95,6 +112,7 @@ The arguments to `stemcell:build` are:
95112 - ` google ` → ` kvm `
96113 - ` openstack ` → ` kvm `
97114 - ` vsphere ` → ` esxi `
115+ - ` warden ` → ` warden `
981163 . ` operating_system_name ` (` ubuntu ` ): Type of OS. Same as
99117 ` stemcell:build_os_image ` .
1001184 . ` operating_system_version ` (` <short_name> ` ): OS release. Same as
@@ -114,7 +132,7 @@ the stemcell would be at
114132upload the stemcell to a vSphere BOSH Director:
115133
116134``` bash
117- export short_name=" noble "
135+ export short_name=" resolute "
118136
119137bosh upload-stemcell tmp/bosh-stemcell-0.0.8-vsphere-esxi-ubuntu-${short_name} -go_agent.tgz
120138```
@@ -135,7 +153,6 @@ the OS image** at the `tmp/ubuntu_base_image.tgz` and you're within the Docker
135153container):
136154
137155``` shell
138- export short_name=" noble"
139156 cd /opt/bosh/bosh-stemcell
140157 bundle install
141158 OS_IMAGE=/opt/bosh/tmp/ubuntu_base_image.tgz bundle exec rspec -fd spec/os_image/ubuntu_spec.rb
@@ -208,7 +225,7 @@ If you find yourself debugging any of the above processes, here is what you need
208225 Example usage:
209226
210227 ``` shell
211- export short_name=" noble "
228+ export short_name=" resolute "
212229
213230 bundle exec rake stemcell:build_os_image[ubuntu,${short_name} ,${PWD} /tmp/ubuntu_base_image.tgz] resume_from=rsyslog_config
214231 ```
@@ -219,8 +236,8 @@ If you find yourself debugging any of the above processes, here is what you need
219236 modifications you can rerun the tests (without rebuilding OS image). Details
220237 in section ` How to run tests for OS Images `
221238* If the Stemcell has been built, and you are only updating tests, you do not
222- need to re-build the stemcell. You can simply rerun the tests - without
223- rebuilding Stemcell. Details in section ` How to run tests for Stemcell `
239+ need to re-build the stemcell. You can simply rerun the tests ( without
240+ rebuilding Stemcell) . Details in section ` How to run tests for Stemcell `
224241* It's possible to verify OS/Stemcell changes without making a deployment using
225242 the stemcell. For a vSphere-specific Ubuntu stemcell, the filesystem is
226243 available at ` /mnt/stemcells/vsphere/esxi/ubuntu/work/work/chroot `
@@ -249,7 +266,7 @@ You will need the ovftool installer present in
249266Rebuild the container with:
250267
251268``` shell
252- export short_name=" noble "
269+ export short_name=" resolute "
253270
254271docker build \
255272 --platform linux/amd64 \
@@ -280,7 +297,7 @@ gsutil cp MY_OVFTOOL_FILE gs://bosh-vmware-ovftool/MY_OS/
280297Example:
281298
282299``` shell
283- export short_name=" noble "
300+ export short_name=" resolute "
284301
285302gsutil cp VMware-ovftool-4.4.3-18663434-lin.x86_64.bundle gs://bosh-vmware-ovftool/${short_name} /
286303```
@@ -387,4 +404,3 @@ When switching from the old pipeline to the new one, don't forget to:
387404 whatever the public bucket should be
388405* update the tasks YAML to point to tasks in the ` os-images ` directory
389406* rename this directory from ` new `
390-
0 commit comments