Skip to content

Commit

Permalink
Update Jammy Standard
Browse files Browse the repository at this point in the history
  • Loading branch information
ngardiner committed Jun 11, 2023
1 parent e780919 commit 223c5d7
Show file tree
Hide file tree
Showing 6 changed files with 100 additions and 0 deletions.
6 changes: 6 additions & 0 deletions jammy_standard/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.veid
config
info
logfile
rootfs
ubuntu-22.04-standard_22.04-1_amd64.tar.gz
35 changes: 35 additions & 0 deletions jammy_standard/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@

BASEDIR:=$(shell dab basedir)
include ../Makefile.global

.PHONY: bootstrap global finalize
all: info/init_ok bootstrap global finalize

bootstrap:
dab bootstrap
install -m 0700 runonce.sh ${BASEDIR}/etc/init.d/firstboot
dab exec update-rc.d firstboot defaults
install -m 0700 custom.sh ${BASEDIR}/tmp
dab exec /bin/bash /tmp/custom.sh
dab exec rm -f /tmp/custom.sh || exit 0

finalize:
dab finalize

info/init_ok: dab.conf
dab init
touch $@

.PHONY: template
template:
cp ubuntu-20.04-standard_20.04-1_amd64.tar.gz /var/lib/vz/template/cache

.PHONY: clean
clean:
dab clean
rm -f *~

.PHONY: dist-clean
dist-clean:
dab dist-clean
rm -f *~
6 changes: 6 additions & 0 deletions jammy_standard/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Ubuntu Jammy Standard Install

- Built from a standard debootstrap install of Ubuntu Jammy
- Adds any customizations such as root login enabled or SSH keys from ../Makefile.global
- Total uncompressed image size is *932 MB*
- Total compressed image size is *172 MB*
3 changes: 3 additions & 0 deletions jammy_standard/custom.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash

exit 0
13 changes: 13 additions & 0 deletions jammy_standard/dab.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Suite: jammy
CacheDir: ../cache
Source: http://ftp.ubuntu.com/ubuntu SUITE main restricted universe multiverse
Source: http://ftp.ubuntu.com/ubuntu SUITE-updates main restricted universe multiverse
Source: http://ftp.ubuntu.com/ubuntu SUITE-security main restricted universe multiverse
Architecture: amd64
Name: standard
Version: 22.04-1
Section: system
Maintainer: Nathan Gardiner <[email protected]>
Infopage: http://www.ubuntu.com
Description: Ubuntu Jammy 22.04 (standard)
A standard Ubuntu Jammy system with template customizations.
37 changes: 37 additions & 0 deletions jammy_standard/runonce.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
#!/bin/bash
### BEGIN INIT INFO
# Provides: firstboot
# Required-Start: $local_fs
# Required-Stop:
# Should-Start: $network $portmap nfs-common udev-mtab
# Default-Start: S
# Default-Stop:
# Short-Description: First-boot system customization routines
# Description: Provides first-boot system customization for
# proxmox container templates.
# Removes itself entirely when done.
### END INIT INFO

case "$1" in
start)

# Put first boot routines here

# Once the script has completed execution, delete ourselves
update-rc.d firstboot disable
rm $0
;;
stop)
echo "Not Implemented"
;;
status)
echo "Not Implemented"
;;
restart|force-reload)
echo "Not Implemented"
;;
*)
echo "Usage: /etc/init.d/$NAME {start}" >&2
exit 1
;;
esac

0 comments on commit 223c5d7

Please sign in to comment.