diff --git a/.github/workflows/build_vars.yml b/.github/workflows/build_vars.yml index e574c150..ffbe6149 100644 --- a/.github/workflows/build_vars.yml +++ b/.github/workflows/build_vars.yml @@ -10,40 +10,19 @@ on: { "version": [ "39", - "40", - ], + "40", + "41" + ], "flatpaks": [ "false", - "flatpak_dir", + "flatpak_refs_dir", "flatpak_refs" ], - "exclude": [ - { - "version": "40", - "flatpaks": "flatpak_dir" - }, - { - "version": "40", - "flatpaks": "flatpak_refs" - } + "image_repo": [ + "ghcr.io/ublue-os" ], - "include": [ - { - "version": "39", - "image_repo": "quay.io/fedora-ostree-desktops", - "image_name": "base" - }, - { - "version": "40", - "image_repo": "quay.io/fedora", - "image_name": "fedora-bootc" - }, - { - "version": "38", - "image_repo": "quay.io/fedora", - "image_name": "fedora-bootc", - "image_src": "docker://quay.io/fedora-ostree-desktops/base:39" - } + "image_name": [ + "base-main" ] }' VARIANT: diff --git a/flatpaks/Makefile b/flatpaks/Makefile index 3b6e939f..7729d01d 100644 --- a/flatpaks/Makefile +++ b/flatpaks/Makefile @@ -14,6 +14,7 @@ repo: script.sh script.sh: cat << EOF > script.sh + which flatpak &> /dev/null || dnf install -y flatpak mkdir -p /flatpak/flatpak /flatpak/triggers mkdir /var/tmp || true chmod -R 1777 /var/tmp diff --git a/lorax_templates/flatpak_set_repo.tmpl b/lorax_templates/flatpak_set_repo.tmpl index 0d8db433..b7fae2dc 100644 --- a/lorax_templates/flatpak_set_repo.tmpl +++ b/lorax_templates/flatpak_set_repo.tmpl @@ -1,8 +1,8 @@ <%page args="flatpak_remote_name, _flatpak_repo_url, version"/> % if int(version) >= 41: +append etc/anaconda/conf.d/anaconda.conf "[Payload]" append etc/anaconda/conf.d/anaconda.conf "flatpak_remote = ${flatpak_remote_name} ${_flatpak_repo_url}" % else: replace "flatpak_manager\.add_remote\(\".*\", \".*\"\)" "flatpak_manager.add_remote(\"${flatpak_remote_name}\", \"${_flatpak_repo_url}\")" /usr/lib64/python*/site-packages/pyanaconda/modules/payloads/payload/rpm_ostree/flatpak_installation.py replace "flatpak_manager\.replace_installed_refs_remote\(\".*\"\)" "flatpak_manager.replace_installed_refs_remote(\"${flatpak_remote_name}\")" /usr/lib64/python*/site-packages/pyanaconda/modules/payloads/payload/rpm_ostree/flatpak_installation.py % endif - diff --git a/test/iso/flatpak_repo_updated.sh b/test/iso/flatpak_repo_updated.sh index 83f37730..c8187ff1 100644 --- a/test/iso/flatpak_repo_updated.sh +++ b/test/iso/flatpak_repo_updated.sh @@ -1,5 +1,19 @@ #!/bin/bash +if [[ ${VERSION} -ge 41 ]] +then + result=0 + grep "^\[Payload\]" mnt/install/etc/anaconda/conf.d/anaconda.conf > /dev/null || { + echo "Missing [Payload] header" + result=1 + } + grep "^flatpak_remote = ${FLATPAK_REMOTE_NAME} ${_FLATPAK_REPO_URL}" mnt/install/etc/anaconda/conf.d/anaconda.conf > /dev/null || { + echo "Missing flatpak_remote option" + result=1 + } + exit ${result} +fi + add_line=$(grep flatpak_manager.add_remote mnt/install/usr/lib64/python*/site-packages/pyanaconda/modules/payloads/payload/rpm_ostree/flatpak_installation.py) add_line_repo=$(echo "${add_line}" | grep "${FLATPAK_REMOTE_NAME}") diff --git a/test/vm/flatpak_fedora_repo_disabled.yml b/test/vm/flatpak_fedora_repo_disabled.yml index 17a3e08d..eb870995 100644 --- a/test/vm/flatpak_fedora_repo_disabled.yml +++ b/test/vm/flatpak_fedora_repo_disabled.yml @@ -10,7 +10,9 @@ register: services_state - name: Check that flatpak-add-fedora-repos is disabled + when: services_state['ansible_facts']['services']['flatpak-add-fedora-repos.service'] is defined ansible.builtin.assert: that: - services_state['ansible_facts']['services']['flatpak-add-fedora-repos.service']['status'] == 'disabled' - fail_msg: 'flatpak-add-fedora-repos.service is not disabled' \ No newline at end of file + fail_msg: 'flatpak-add-fedora-repos.service is not disabled' + success_msg: 'flatpak-add-fedora-repos.service is correctly disabled'