Skip to content

Commit

Permalink
upgrade to ubuntu 22.04 (jammy jellyfish)
Browse files Browse the repository at this point in the history
  • Loading branch information
rgl committed Apr 21, 2022
1 parent 2611512 commit 65faa3a
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 16 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
SHELL=bash
.SHELLFLAGS=-euo pipefail -c

VERSION=21.10
VERSION=22.04

help:
@echo type make build-libvirt, make build-uefi-libvirt, make build-virtualbox, make build-hyperv or make build-vsphere
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
This builds an up-to-date Vagrant Ubuntu Base Box as described at the [From Iso To Vagrant Box](http://blog.ruilopes.com/from-iso-to-vagrant-box.html) article.

Currently this targets [Ubuntu 21.10 (Impish Indri)](https://wiki.ubuntu.com/ImpishIndri/ReleaseNotes).
Currently this targets [Ubuntu 22.04 (Jammy Jellyfish)](https://wiki.ubuntu.com/JammyJellyfish/ReleaseNotes).

Other Ubuntu versions might be available in a [separate branch](https://github.com/rgl/ubuntu-vagrant/branches).

Expand Down Expand Up @@ -175,10 +175,10 @@ export GOVC_PASSWORD='password'
export GOVC_DATACENTER='Datacenter'
export GOVC_CLUSTER='Cluster'
export GOVC_DATASTORE='Datastore'
export VSPHERE_OS_ISO="[$GOVC_DATASTORE] iso/ubuntu-21.10-live-server-amd64.iso"
export VSPHERE_OS_ISO="[$GOVC_DATASTORE] iso/ubuntu-22.04-live-server-amd64.iso"
export VSPHERE_ESXI_HOST='esxi.local'
export VSPHERE_TEMPLATE_FOLDER='test/templates'
export VSPHERE_TEMPLATE_NAME="$VSPHERE_TEMPLATE_FOLDER/ubuntu-21.10-amd64-vsphere"
export VSPHERE_TEMPLATE_NAME="$VSPHERE_TEMPLATE_FOLDER/ubuntu-22.04-amd64-vsphere"
export VSPHERE_VM_FOLDER='test'
export VSPHERE_VM_NAME='ubuntu-vagrant-example'
export VSPHERE_VLAN='packer'
Expand Down
4 changes: 2 additions & 2 deletions example/Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ cloud_init_user_data = {
}

Vagrant.configure(2) do |config|
config.vm.box = 'ubuntu-21.10-amd64'
#config.vm.box = 'ubuntu-21.10-uefi-amd64'
config.vm.box = 'ubuntu-22.04-amd64'
#config.vm.box = 'ubuntu-22.04-uefi-amd64'

config.vm.hostname = 'example.test'

Expand Down
4 changes: 2 additions & 2 deletions provision-local-hyperv.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
# also shows example values):
#
# PACKER_VERSION 1.6.0
# PACKER_VM_NAME packer-ubuntu-21.10-amd64-hyperv
# PACKER_BUILD_NAME ubuntu-21.10-amd64-hyperv
# PACKER_VM_NAME packer-ubuntu-22.04-amd64-hyperv
# PACKER_BUILD_NAME ubuntu-22.04-amd64-hyperv
# PACKER_BUILDER_TYPE hyperv-iso
# PACKER_HTTP_ADDR 10.0.0.123:1
# PACKER_HTTP_IP 10.0.0.123
Expand Down
12 changes: 6 additions & 6 deletions provision.sh
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,12 @@ rm -f /var/lib/dbus/machine-id
# reset the random-seed.
# NB systemd-random-seed re-generates it on every boot and shutdown.
# NB you can prove that random-seed file does not exist on the image with:
# sudo virt-filesystems -a ~/.vagrant.d/boxes/ubuntu-21.10-amd64/0/libvirt/box.img
# sudo mkdir /mnt/ubuntu-21.10-amd64
# sudo guestmount -a ~/.vagrant.d/boxes/ubuntu-21.10-amd64/0/libvirt/box.img -m /dev/sda1 --pid-file guestmount.pid --ro /mnt/ubuntu-21.10-amd64
# sudo bash -c 'unmkinitramfs /mnt/ubuntu-21.10-amd64/boot/initrd.img /tmp/ubuntu-21.10-amd64-initrd' # NB prefer unmkinitramfs over cpio.
# sudo ls -laF /mnt/var/lib/systemd
# sudo guestunmount /mnt/ubuntu-21.10-amd64
# sudo virt-filesystems -a ~/.vagrant.d/boxes/ubuntu-22.04-amd64/0/libvirt/box.img
# sudo mkdir /mnt/ubuntu-22.04-amd64
# sudo guestmount -a ~/.vagrant.d/boxes/ubuntu-22.04-amd64/0/libvirt/box.img -m /dev/sda1 --pid-file guestmount.pid --ro /mnt/ubuntu-22.04-amd64
# sudo bash -c 'unmkinitramfs /mnt/ubuntu-22.04-amd64/boot/initrd.img /tmp/ubuntu-22.04-amd64-initrd' # NB prefer unmkinitramfs over cpio.
# sudo ls -laF /mnt/ubuntu-22.04-amd64/var/lib/systemd
# sudo guestunmount /mnt/ubuntu-22.04-amd64
# sudo bash -c 'while kill -0 $(cat guestmount.pid) 2>/dev/null; do sleep .1; done; rm guestmount.pid' # wait for guestmount to finish.
# see https://www.freedesktop.org/software/systemd/man/systemd-random-seed.service.html
# see https://manpages.ubuntu.com/manpages/bionic/man4/random.4.html
Expand Down
4 changes: 2 additions & 2 deletions ubuntu.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ variable "disk_size" {

variable "iso_url" {
type = string
default = "https://releases.ubuntu.com/21.10/ubuntu-21.10-live-server-amd64.iso"
default = "https://releases.ubuntu.com/22.04/ubuntu-22.04-live-server-amd64.iso"
}

variable "iso_checksum" {
type = string
default = "sha256:e84f546dfc6743f24e8b1e15db9cc2d2c698ec57d9adfb852971772d1ce692d4"
default = "sha256:84aeaf7823c8c61baa0ae862d0a06b03409394800000b3235854a6b38eb4856f"
}

variable "hyperv_switch_name" {
Expand Down

0 comments on commit 65faa3a

Please sign in to comment.