Skip to content

Commit

Permalink
Add bookwork distro
Browse files Browse the repository at this point in the history
  • Loading branch information
ngardiner committed Jun 11, 2023
1 parent 26df0c9 commit 38a3806
Show file tree
Hide file tree
Showing 15 changed files with 209 additions and 7 deletions.
6 changes: 6 additions & 0 deletions bookworm_minimal/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.veid
config
info
logfile
rootfs
debian-11-minimal_11.0-1_amd64.tar.gz
36 changes: 36 additions & 0 deletions bookworm_minimal/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@

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

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

bootstrap:
dab bootstrap --minimal
dab install apt-transport-https ca-certificates locales ntpdate
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

finalize:
dab finalize

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

.PHONY: template
template:
cp debian-9.0-minimal_9.4-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 *~
7 changes: 7 additions & 0 deletions bookworm_minimal/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Debian Bullseye Minimal Install

- Built from a minimal debootstrap install of Debian Bullseye
- Contains additional important packages such as an NTP Client and CA Certificates
- Adds any customizations such as root login enabled or SSH keys from ../Makefile.global
- Total uncompressed image size is *393 MB*
- Total compressed image size is *143 MB*
3 changes: 3 additions & 0 deletions bookworm_minimal/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 bookworm_minimal/dab.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Suite: bookworm
CacheDir: ../cache
Source: http://ftp.debian.org/debian SUITE main contrib
Source: http://security.debian.org/debian-security SUITE-security/updates main contrib
Source: http://ftp.debian.org/debian SUITE-updates main contrib
Architecture: amd64
Name: minimal
Version: 12.0-1
Section: system
Maintainer: Nathan Gardiner <[email protected]>
Infopage: http://www.debian.org
Description: Debian Bookworm 12.0 (minimal)
A minimal Debian Bookworm system with template customizations.
37 changes: 37 additions & 0 deletions bookworm_minimal/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
6 changes: 6 additions & 0 deletions bookworm_standard/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.veid
config
info
logfile
rootfs
debian-11-standard_11.0-1_amd64.tar.gz
35 changes: 35 additions & 0 deletions bookworm_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

finalize:
dab finalize

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

.PHONY: template
template:
cp debian-10.0-standard_10.0-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 bookworm_standard/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Debian Bullseye Standard Install

- Built from a standard debootstrap install of Debian Bullseye
- Adds any customizations such as root login enabled or SSH keys from ../Makefile.global
- Total uncompressed image size is *900 MB*
- Total compressed image size is *173 MB*
3 changes: 3 additions & 0 deletions bookworm_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 bookworm_standard/dab.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Suite: bookworm
CacheDir: ../cache
Source: http://ftp.debian.org/debian SUITE main contrib
Source: http://security.debian.org/debian-security SUITE-security/updates main contrib
Source: http://ftp.debian.org/debian SUITE-updates main contrib
Architecture: amd64
Name: standard
Version: 12.0-1
Section: system
Maintainer: Nathan Gardiner <[email protected]>
Infopage: http://www.debian.org
Description: Debian Bookworm 12.0 (standard)
A standard Debian Bookworm system with template customizations.
37 changes: 37 additions & 0 deletions bookworm_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
6 changes: 3 additions & 3 deletions trixie_minimal/dab.conf
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
Suite: trixie
Suite: testing
CacheDir: ../cache
Source: http://ftp.debian.org/debian SUITE main contrib
Source: http://security.debian.org/debian-security SUITE-security/updates main contrib
Source: http://ftp.debian.org/debian SUITE-updates main contrib
Architecture: amd64
Name: minimal
Version: 12.0-1
Version: 13.0-1
Section: system
Maintainer: Nathan Gardiner <[email protected]>
Infopage: http://www.debian.org
Description: Debian Trixie 12.0 (minimal)
Description: Debian Trixie 13.0 (minimal)
A minimal Debian Trixie system with template customizations.
4 changes: 2 additions & 2 deletions trixie_standard/dab.conf
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ Source: http://security.debian.org/debian-security SUITE-security/updates main c
Source: http://ftp.debian.org/debian SUITE-updates main contrib
Architecture: amd64
Name: standard
Version: 12.0-1
Version: 13.0-1
Section: system
Maintainer: Nathan Gardiner <[email protected]>
Infopage: http://www.debian.org
Description: Debian Trixie 12.0 (standard)
Description: Debian Trixie 13.0 (standard)
A standard Debian Trixie system with template customizations.
4 changes: 2 additions & 2 deletions xenial_minimal/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
- Built from a minimal debootstrap install of Ubuntu Xenial
- Contains additional important packages such as an NTP Client and CA Certificates
- Adds any customizations such as root login enabled or SSH keys from ../Makefile.global
- Total uncompressed image size is *399 MB*
- Total compressed image size is *126 MB*
- Total uncompressed image size is *424 MB*
- Total compressed image size is *142 MB*

0 comments on commit 38a3806

Please sign in to comment.