Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
002dfd7
Include netplan refactor packages in Azure dpkg list
selzoc Apr 21, 2026
9658d04
Serialize stemcell builds, and remove attempts
selzoc Apr 21, 2026
6501c79
Bump os-image tgz
bosh-admin-bot Apr 21, 2026
9297618
Merge pull request #574 from cloudfoundry/update-azure-dpkg-list-netplan
selzoc Apr 21, 2026
80003d4
Bump os-image tgz
bosh-admin-bot Apr 21, 2026
f7afc2f
Merge pull request #575 from cloudfoundry/serial-and-no-retries-for-b…
selzoc Apr 21, 2026
2c1203c
README: update subnet instructions
aramprice Apr 21, 2026
f33109e
Bump os-image tgz
bosh-admin-bot Apr 21, 2026
ddeea51
bump bosh-agent/2.839.0
bosh-admin-bot Apr 22, 2026
313ca02
Bump os-image tgz
bosh-admin-bot Apr 22, 2026
2238b91
bump bosh-agent/2.840.0
bosh-admin-bot Apr 22, 2026
2c32b2c
Bump os-image tgz
bosh-admin-bot Apr 22, 2026
5c6f3a5
fix cgroupsv1 support in warden
mkocher Apr 16, 2026
435d61f
Bump os-image tgz
bosh-admin-bot Apr 22, 2026
5a097c8
Add PR template
aramprice Apr 23, 2026
d4ec663
Update .github/pull_request_template.md
aramprice Apr 23, 2026
98df527
Update .github/pull_request_template.md
aramprice Apr 23, 2026
f6ae05e
Bump os-image tgz
bosh-admin-bot Apr 23, 2026
728363f
CI: stop defaultling `AGENT_SUFFIX`
aramprice Apr 24, 2026
66a355d
Shell: style nit `${foo}` over `$foo`
aramprice Apr 24, 2026
b5ffe31
Move metalink files to repo root
aramprice Apr 24, 2026
c9d65da
CI: use concourse to fetch OS_IMAGE
aramprice Apr 24, 2026
6addedd
Rename task `stemcell:build_with_local_os_image` -> `:build`
aramprice Apr 24, 2026
d21a0aa
Merge pull request #581 from cloudfoundry/metalink-cleanup
aramprice Apr 24, 2026
11de246
Bump os-image tgz
bosh-admin-bot Apr 24, 2026
efc57d3
Move image-metalinks to prepare for merge
aramprice Apr 25, 2026
87baea5
Merge branch 'ubuntu-jammy' into merge-jammy
aramprice Apr 25, 2026
cd4d01f
Fixup bad merge
aramprice Apr 25, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ bundle install
bundle exec rake stemcell:build_os_image[ubuntu,${short_name},${PWD}/tmp/ubuntu_base_image.tgz]

# build vSphere stemcell
bundle exec rake stemcell:build_with_local_os_image[vsphere,esxi,ubuntu,${short_name},${PWD}/tmp/ubuntu_base_image.tgz]
bundle exec rake stemcell:build[vsphere,esxi,ubuntu,${short_name},${PWD}/tmp/ubuntu_base_image.tgz]
```

When building a vSphere stemcell, you must download `VMware-ovftool-*.bundle`
Expand Down Expand Up @@ -81,10 +81,10 @@ Rebuild the stemcell when you are making and testing BOSH-specific changes such
export short_name="noble"
export build_number="0.0.8"

bundle exec rake stemcell:build_with_local_os_image[vsphere,esxi,ubuntu,${short_name},${PWD}/tmp/ubuntu_base_image.tgz,${build_number}]
bundle exec rake stemcell:build[vsphere,esxi,ubuntu,${short_name},${PWD}/tmp/ubuntu_base_image.tgz,${build_number}]
```

The arguments to `stemcell:build_with_local_os_image` are:
The arguments to `stemcell:build` are:

1. `infrastructure_name`: Which IaaS you are producing the stemcell for.
Determines which virtualization tools to package on top of the stemcell.
Expand Down Expand Up @@ -143,11 +143,11 @@ container):

### How to Run Tests for Stemcell

When you run the `stemcell:build_with_local_os_image` or `stemcell:build` rake
task, it will create a stemcell that it runs the stemcell specific tests
against. You will need to run the **rake task the first time you create your
docker container**, but everytime after, as long as you do not destroy the
container, you should be able to run the specific tests:
When you run the `stemcell:build` rake task, it will create a stemcell that it
runs the stemcell-specific tests against. You will need to run the **rake task
the first time you create your docker container**, but every time after, as
long as you do not destroy the container, you should be able to run the
specific tests:

```shell
cd /opt/bosh/bosh-stemcell; \
Expand Down
54 changes: 2 additions & 52 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -42,58 +42,8 @@ namespace :stemcell do
end
end

desc 'Download a remote pre-built base OS image'
task :download_os_image, [:operating_system_name, :operating_system_version] do |_, args|
begin
puts "Using OS image #{args.operating_system_name}-#{args.operating_system_version}"

mkdir_p('tmp')

metalink_path = File.join(
Dir.pwd,
'bosh-stemcell',
'image-metalinks',
"#{args.operating_system_name}-#{args.operating_system_version}.meta4"
)

os_image_path = File.join(Dir.pwd, 'tmp', 'base_os_image.tgz')
`meta4 file-download --file #{args.operating_system_name}-#{args.operating_system_version}.tgz --metalink #{metalink_path} #{os_image_path}`
raise 'Failed to download metalink' if $?.exitstatus != 0

puts "Successfully downloaded OS image to #{os_image_path}"
rescue RuntimeError => e
print_help
raise e
end
end

desc 'Build a stemcell with a remote pre-built base OS image'
task :build, [:infrastructure_name, :hypervisor_name, :operating_system_name, :operating_system_version, :build_number] do |_, args|
begin
Rake::Task['stemcell:download_os_image'].invoke(
args.operating_system_name,
args.operating_system_version
)

os_image_path = File.join(Dir.pwd, 'tmp', 'base_os_image.tgz')
args.with_defaults(build_number: '0000')

Rake::Task['stemcell:build_with_local_os_image'].invoke(
args.infrastructure_name,
args.hypervisor_name,
args.operating_system_name,
args.operating_system_version,
os_image_path,
args.build_number
)
rescue RuntimeError => e
print_help
raise e
end
end

desc 'Build a stemcell using a local pre-built base OS image'
task :build_with_local_os_image, [:infrastructure_name, :hypervisor_name, :operating_system_name, :operating_system_version, :os_image_path, :build_number] do |_, args|
desc 'Build a stemcell, requires `os_image_path` pointing at an image created via `stemcell:build_os_image`'
task :build, [:infrastructure_name, :hypervisor_name, :operating_system_name, :operating_system_version, :os_image_path, :build_number] do |_, args|
Comment thread
aramprice marked this conversation as resolved.
begin
require 'bosh/stemcell/build_environment'
require 'bosh/stemcell/definition'
Expand Down
21 changes: 0 additions & 21 deletions bosh-stemcell/image-metalinks/ubuntu_noble_poc/ubuntu-noble.meta4

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,13 @@ linux-cloud-tools-6.8
linux-cloud-tools-6.8-generic
linux-cloud-tools-common
linux-cloud-tools-generic
netplan-generator
netplan.io
python-is-python3
python3-attr
python3-certifi
python3-chardet
python3-configobj
python3-debconf
python3-netplan
python3-idna
python3-jinja2
python3-json-pointer
Expand Down
6 changes: 3 additions & 3 deletions ci/pipelines/builder.yml
Original file line number Diff line number Diff line change
Expand Up @@ -492,7 +492,7 @@ jobs:
params:
files:
- stemcell/*.tgz
rename: "{{.Version}}/(@= IAAS @)-(@= HYPERVISOR @)(@= FIPS @).meta4"
rename: "{{.Version}}/(@= IAAS @)-(@= HYPERVISOR @)(@= FIPS @)(@= data.values.stemcell_details.agent_suffix @).meta4"
options:
author_email: *ci_bot_email
author_name: *ci_bot_name
Expand Down Expand Up @@ -943,7 +943,7 @@ resources:
private_key: ((github_deploy_key_bosh-linux-stemcell-builder.private_key))
filters:
- repositorypath: "(@= data.values.stemcell_details.branch @)/(@= data.values.stemcell_details.os_name @).meta4"
uri: git+ssh://git@github.com/cloudfoundry/bosh-linux-stemcell-builder.git//bosh-stemcell/image-metalinks/#(@= data.values.stemcell_details.branch @)
uri: git+ssh://git@github.com/cloudfoundry/bosh-linux-stemcell-builder.git//image-metalinks/#(@= data.values.stemcell_details.branch @)
url_handlers:
- include:
- (s3|https)://.*
Expand Down Expand Up @@ -981,7 +981,7 @@ resources:
branch: (@= data.values.stemcell_details.branch @)
ignore_paths:
- ci
- bosh-stemcell/image-metalinks/
- image-metalinks
- VERSION
uri: https://github.com/cloudfoundry/bosh-linux-stemcell-builder

Expand Down
2 changes: 1 addition & 1 deletion ci/tasks/build-release-metadata.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ if [[ "${OS_NAME}" == "ubuntu" ]]; then
# Ensure URL for usn-log from metalink exists before attempting to download.
usn_log_json_file="${REPO_PARENT}/bosh-linux-stemcell-builder/usn-log.json"
touch "${usn_log_json_file}"
usn_metalink_path="${REPO_PARENT}/bosh-linux-stemcell-builder/bosh-stemcell/image-metalinks/${BRANCH}/${OS_NAME}-${OS_VERSION}.meta4"
usn_metalink_path="${REPO_PARENT}/bosh-linux-stemcell-builder/image-metalinks/${BRANCH}/${OS_NAME}-${OS_VERSION}.meta4"
if [[ -n "$(meta4 file-urls --metalink "${usn_metalink_path}" --file usn-log.json)" ]]; then
meta4 file-download \
--skip-hash-verification \
Expand Down
17 changes: 4 additions & 13 deletions ci/tasks/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ check_param HYPERVISOR
check_param OS_NAME
check_param OS_VERSION

OS_IMAGE="$(readlink -f "${REPO_PARENT}/os-image-tarball"/*.tgz)"

Comment thread
aramprice marked this conversation as resolved.
export CANDIDATE_BUILD_NUMBER=$( cat "${REPO_PARENT}/version/number" | sed 's/\.0$//;s/\.0$//' )

git clone "${REPO_PARENT}/stemcells-index" "${REPO_PARENT}/stemcells-index-output"
Expand Down Expand Up @@ -73,26 +75,15 @@ done
chown -R ubuntu:ubuntu "${REPO_ROOT}" # ci resource
chown -R ubuntu:ubuntu "${REPO_PARENT}/bosh-linux-stemcell-builder"
chown -R ubuntu:ubuntu /mnt

OS_IMAGE=""
mkdir -p "${REPO_PARENT}/os-image-tarball"
if [[ -n "$(ls -A "${REPO_PARENT}/os-image-tarball/")" ]]; then
OS_IMAGE="$(readlink -f "${REPO_PARENT}/os-image-tarball"/*.tgz)"
fi

sudo chmod u+s "$(which sudo)"

sudo --preserve-env --set-home --user ubuntu -- /bin/bash --login -i <<SUDO
set -e

cd "${REPO_PARENT}/bosh-linux-stemcell-builder"
bundle install

if [[ -z "${OS_IMAGE}" ]]; then
bundle exec rake stemcell:build[${IAAS},${HYPERVISOR},${OS_NAME},${OS_VERSION},${CANDIDATE_BUILD_NUMBER}]
rm -f ./tmp/base_os_image.tgz
else
bundle exec rake stemcell:build_with_local_os_image[${IAAS},${HYPERVISOR},${OS_NAME},${OS_VERSION},${OS_IMAGE},${CANDIDATE_BUILD_NUMBER}]
fi
bundle exec rake stemcell:build[${IAAS},${HYPERVISOR},${OS_NAME},${OS_VERSION},${OS_IMAGE},${CANDIDATE_BUILD_NUMBER}]
SUDO

#
Expand Down
1 change: 0 additions & 1 deletion ci/tasks/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ inputs:
- name: version
- name: stemcells-index
- name: os-image-tarball
optional: true

outputs:
- name: stemcell
Expand Down
15 changes: 9 additions & 6 deletions ci/tasks/os-images/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,25 +18,28 @@ function check_param() {
exit 1
fi
}

check_param OPERATING_SYSTEM_NAME
check_param OPERATING_SYSTEM_VERSION

OS_IMAGE_NAME=${OPERATING_SYSTEM_NAME}-${OPERATING_SYSTEM_VERSION}
OS_IMAGE=${REPO_PARENT}/os-image/${OS_IMAGE_NAME}.tgz

if [ -f "${REPO_PARENT}/build-time/timestamp" ]; then
build_time="$(cat "${REPO_PARENT}/build-time/timestamp")"
export BUILD_TIME="$(date --date "${build_time%.*}" +%Y%m%dT%H%M%SZ)"
fi

sudo chown -R ubuntu .
sudo chown -R ubuntu:ubuntu /mnt
chown -R ubuntu:ubuntu "${REPO_ROOT}" # ci resource
chown -R ubuntu:ubuntu "${REPO_PARENT}/bosh-linux-stemcell-builder"
chown -R ubuntu:ubuntu /mnt
sudo chmod u+s "$(which sudo)"

sudo --preserve-env --set-home --user ubuntu -- /bin/bash --login -i <<SUDO
set -e

pushd "${REPO_PARENT}/bosh-linux-stemcell-builder"
bundle install
bundle exec rake stemcell:build_os_image[$OPERATING_SYSTEM_NAME,$OPERATING_SYSTEM_VERSION,$OS_IMAGE]
popd
cd "${REPO_PARENT}/bosh-linux-stemcell-builder"
bundle install

bundle exec rake stemcell:build_os_image[$OPERATING_SYSTEM_NAME,$OPERATING_SYSTEM_VERSION,$OS_IMAGE]
SUDO
22 changes: 22 additions & 0 deletions image-metalinks/ubuntu-jammy/ubuntu-jammy.meta4
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<metalink xmlns="urn:ietf:params:xml:ns:metalink">
<file name="ubuntu-jammy.tgz">
<hash type="sha-512">4d63eb6d8d7eba07628372c969bfdf3a778a66ef77e85616a84f900c603dc53c63c314bb2ded2e073f81e5243507fb3d58ad8f9d84fde0e16bc01f6d2221c616</hash>
<hash type="sha-256">8bf6a4b8a98d71b4c26f41ce4b8622c939de05d82dabdd0ea8e03d44de843db6</hash>
<hash type="sha-1">d21ab0b19c1a3f52bb7e348b69b28663ee676503</hash>
<hash type="md5">f0210c187eb07d66f8ea31f796a4aa76</hash>
<size>434793371</size>
<url>https://storage.googleapis.com/bosh-os-images/ubuntu-jammy/ubuntu-jammy.tgz</url>
<version>1043.0.0</version>
</file>
<file name="usn-log.json">
<hash type="sha-512">ca3e99837fae81c10f5522a623fab715b1e430f7895b1f202bae32ccfe3a6f80ad79cffcbd789adcf099de7b00f7cc8c31ebbb3aeb5c0e13aa7decea88bc1559</hash>
<hash type="sha-256">d12b345d3cf6c8127c05e8f702efd18966bf59378830efc14cef784a5248a88e</hash>
<hash type="sha-1">ade2522e3d639fff8df5117dea1870b605ed52a6</hash>
<hash type="md5">6c72c53f5bb8d8d05dd9b377f3beb937</hash>
<size>869</size>
<url>https://storage.googleapis.com/bosh-os-images/ubuntu-jammy/usn-log.json</url>
<version>1043.0.0</version>
</file>
<generator>metalink-repository-resource/0.0.0</generator>
<published>2026-04-24T23:46:02.968990444Z</published>
</metalink>
Loading