1
0
Fork 0
mirror of https://github.com/JasonN3/build-container-installer.git synced 2025-12-25 10:57:55 +01:00

add clean

This commit is contained in:
Jason N. 2024-02-14 19:07:28 +00:00
parent d4347902f2
commit 81bcbb56ca
6 changed files with 26 additions and 7 deletions

View file

@ -3,6 +3,7 @@ version = "39"
base_dir = $(shell pwd) base_dir = $(shell pwd)
image_repo = "ghcr.io/ublue-os" image_repo = "ghcr.io/ublue-os"
image_name = "base-main" image_name = "base-main"
subdir = "lorax_templates xorriso"
deploy.iso: boot.iso xorriso/input.txt $(image_name)-$(version) deploy.iso: boot.iso xorriso/input.txt $(image_name)-$(version)
xorriso -dialog on < xorriso/input.txt xorriso -dialog on < xorriso/input.txt
@ -25,3 +26,12 @@ $(image_name)-$(version):
install-deps: install-deps:
dnf install -y lorax xorriso podman git rpm-ostree dnf install -y lorax xorriso podman git rpm-ostree
clean:
rm -f boot.iso
rm -f deploy.iso
rm -Rf $(image_name)-$(version)
for dir in $(subdir) ; do \
$(MAKE) -C $$dir clean ; \
done

View file

@ -1,4 +1,7 @@
%.tmpl: %.tmpl:
sed -i 's/@IMAGE_NAME@/$(image_name)' $* sed 's/@IMAGE_NAME@/$(image_name)' $*.in > $*
sed -i 's/@IMAGE_REPO@/$(image_repo)' $* sed 's/@IMAGE_REPO@/$(image_repo)' $* > $*
sed -i 's/@VERSION@/$(version)' $* sed 's/@VERSION@/$(version)' $* $*
clean:
rm *.tmpl

View file

@ -1,4 +1,9 @@
input.txt: input.txt: gen_input.sh
sed -i 's/@IMAGE_NAME@/$(image_name)-$(version)/' gen_input.sh bash gen_input.sh "$(base_dir)" > input.txt
cd $(base_dir)
bash gen_input.sh > input.txt %.sh:
sed 's/@IMAGE_NAME@/$(image_name)-$(version)/' $*.in > $*
clean:
rm input.txt
rm gen_input.sh

View file

@ -6,6 +6,7 @@ echo "-boot_image any replay"
echo "-volid Fedora-S-dvd-x86_64-39" echo "-volid Fedora-S-dvd-x86_64-39"
echo "-joliet on" echo "-joliet on"
echo "-compliance joliet_long_names" echo "-compliance joliet_long_names"
cd $1
for file in $(find @IMAGE_NAME@) for file in $(find @IMAGE_NAME@)
do do
echo "-map $(pwd)/${file} ${file}" echo "-map $(pwd)/${file} ${file}"