mirror of
https://github.com/JasonN3/build-container-installer.git
synced 2025-12-25 10:57:55 +01:00
add flatpaks
This commit is contained in:
parent
88d7731848
commit
90edae91c1
5 changed files with 32 additions and 3 deletions
9
Makefile
9
Makefile
|
|
@ -9,6 +9,10 @@ VARIANT = Server
|
|||
WEB_UI = false
|
||||
REPOS = /etc/yum.repos.d/fedora.repo /etc/yum.repos.d/fedora-updates.repo
|
||||
ADDITIONAL_TEMPLATES = ""
|
||||
FLATPAK_REMOTE_NAME = flathub
|
||||
FLATPAK_REMOTE_URL = https://dl.flathub.org/repo/
|
||||
FLATPAK_REMOTE_REFS =
|
||||
|
||||
ROOTFS_SIZE = 4
|
||||
|
||||
# Generated vars
|
||||
|
|
@ -19,6 +23,8 @@ _IMAGE_REPO_DOUBLE_ESCAPED = $(subst \,\\\,$(_IMAGE_REPO_ESCAPED))
|
|||
_VOLID = $(firstword $(subst -, ,$(IMAGE_NAME)))-$(ARCH)-$(IMAGE_TAG)
|
||||
_REPO_FILES = $(subst /etc/yum.repos.d,repos,$(REPOS))
|
||||
_LORAX_TEMPLATES = $(subst .in,,$(shell ls lorax_templates/*.tmpl.in))
|
||||
_FLATPAK_TEMPLATES = $(_BASE_DIR)/external/fedora-lorax-templates/ostree-based-installer/lorax-embed-flatpaks.tmpl
|
||||
_TEMPLATE_VARS = FLATPAK_REMOTE_NAME FLATPAK_REMOTE_URL FLATPAK_REMOTE_REFS
|
||||
|
||||
ifeq ($(VARIANT),Server)
|
||||
_LORAX_ARGS = --macboot --noupgrade
|
||||
|
|
@ -42,7 +48,6 @@ lorax_templates/%.tmpl: lorax_templates/%.tmpl.in
|
|||
$(eval _VARS = IMAGE_NAME IMAGE_TAG _IMAGE_REPO_DOUBLE_ESCAPED)
|
||||
$(foreach var,$(_VARS),$(var)=$($(var))) envsubst '$(foreach var,$(_VARS),$$$(var))' < $(_BASE_DIR)/lorax_templates/$*.tmpl.in > $(_BASE_DIR)/lorax_templates/$*.tmpl
|
||||
|
||||
|
||||
# Step 2: Replace vars in repo files
|
||||
repos/%.repo: /etc/yum.repos.d/%.repo
|
||||
mkdir repos || true
|
||||
|
|
@ -63,7 +68,9 @@ boot.iso: $(_LORAX_TEMPLATES) $(_REPO_FILES)
|
|||
$(foreach file,$(_REPO_FILES),--repo $(_BASE_DIR)/$(file)) \
|
||||
$(foreach file,$(_LORAX_TEMPLATES),--add-template $(_BASE_DIR)/$(file)) \
|
||||
$(foreach file,$(ADDITIONAL_TEMPLATES),--add-template $(file)) \
|
||||
$(foreach file,$(_FLATPAK_TEMPLATES),--add-template $(file)) \
|
||||
--rootfs-size $(ROOTFS_SIZE) \
|
||||
$(foreach var,$(_TEMPLATE_VARS),--add-template-var "$(var)=$($(var))") \
|
||||
$(_BASE_DIR)/results/
|
||||
mv $(_BASE_DIR)/results/images/boot.iso $(_BASE_DIR)/
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue