Managing Flatpak repositories in orcharhino
Flatpak allows users to install, manage, and run portable applications on orcharhino, primarily for desktop environments. In orcharhino, you can integrate Flatpak repositories to distribute and control Flatpak applications across managed hosts. By configuring Flatpak repositories, you ensure that systems have access to the necessary application packages while maintaining centralized control over application deployment.
Flatpak repositories function similarly to other content repositories in orcharhino. You can synchronize, manage access permissions, and assign repositories to specific lifecycle environments to control which applications are available to systems. You can also use Hammer CLI to manage Flatpak repositories.
Enabling the Flatpak remote
This procedure configures and manages Flatpak repositories by using Hammer CLI.
-
Your orcharhino account has a role that grants the permissions
view_flatpak_remotes
,create_flatpak_remotes
,edit_flatpak_remotes
, anddestroy_flatpak_remotes
. -
Set up Flatpak.
-
Flatpak applications rely on Flatpak runtimes. For example,
rhel9/firefox-flatpak
depends onrhel9/flatpak-runtime
. -
Ensure that runtime repositories are available to clients alongside application repositories for installations to work.
-
Enable a Flatpak remote on the orcharhino Server by using standalone Debian systems or orcharhino:
$ hammer flatpak-remote create \ --name=My_Flatpak_Remote_Name \ --organization=My_Organization \ --url=My_Flatpak_Remote_URL
You can include authentication details by using the options
--username=My_User_Name --token=My_Token
. -
Update the Flatpak remote with authentication credentials:
$ hammer flatpak-remote update \ --id My_Flatpak_Remote_ID \ --token=My_Token \ --username=My_User_Name
-
Optional: List and view information about the Flatpak remote:
$ hammer flatpak-remote list $ hammer flatpak-remote info --id My_Flatpak_Remote_ID
-
Scan the Flatpak remote:
$ hammer flatpak-remote scan --id=My_ID
-
List repositories in the Flatpak remote:
$ hammer flatpak-remote remote-repository list --flatpak-remote-id=My_ID
-
Mirror a Flatpak remote repository to a orcharhino product:
$ hammer flatpak-remote remote-repository mirror \ --id=My_Remote_Repo_ID \ --product-id=orcharhino_Product_ID
You can view the repository under the selected product in orcharhino management UI. Set the Include Tags field to latest.
-
Synchronize the orcharhino repository:
$ hammer repository sync --id=My_Repo_ID
Installing Flatpak applications on orcharhino hosts
Use the command line to install selected applications from the enabled Flatpak remotes.
-
Install Flatpak.
-
On the managed host, add your orcharhino Server as a Flatpak remote:
$ flatpak remote-add --authenticator-name=org.flatpak.Authenticator.Oci katello oci+https://orcharhino.example.com/
-
Log in using Podman:
$ podman login
-
Install your application. For example, to install the Mozilla Firefox Flatpak:
$ flatpak install firefox
Setting up Flatpak remote for orcharhino Proxy
Configure orcharhino Proxy Servers to synchronize and distribute Flatpak repositories to managed hosts.
orcharhino Proxies synchronize Flatpaks and make them available to all hosts, but not organizations, content views, or lifecycle environments. Clients receive the latest Flatpaks synchronized on the orcharhino Proxy globally. |
-
Synchronize Flatpak repositories to the orcharhino Proxy. For more information, see Synchronizing Repositories.
-
On the managed host, add the orcharhino Proxy as a Flatpak remote:
$ flatpak remote-add --authenticator-name=org.flatpak.Authenticator.Oci katello oci+https://orcharhino-proxy.network2.example.com/pulpcore_registry/
-
Log in using Podman:
$ podman login
For more information about logging in using Podman, see Configuring podman to trust the CA.
You might need to log in to the registry again if you have not saved your credentials.
-
Optional: Save your credentials permanently using one of the following options:
-
To save the credentials for the current user:
$ cp $XDG_RUNTIME_DIR/containers/auth.json $HOME/.config/flatpak/oci-auth.json
-
To save the credentials system-wide:
$ cp $XDG_RUNTIME_DIR/containers/auth.json /etc/flatpak/oci-auth.json
-
-
Install your application. For example, to install the Mozilla Firefox Flatpak:
$ flatpak install firefox
Importing and exporting content to orcharhino Server for Flatpak
Use Hammer CLI to transfer Flatpak content to orcharhino Server in environments with disconnected orcharhino Server instances.
-
Enable the Flatpak remote. For more information about enabling the Flatpak remote, see enabling the flatpak remote.
-
Use download policy Immediate to synchronize Flatpak content to orcharhino Server. For more information, see changing the download policy for a repository.
-
On your connected orcharhino Server, export your Flatpak repository:
$ hammer content-export complete repository \ --id My_Repository_ID
-
Transfer the Flatpak repository from your connected orcharhino Server to your disconnected orcharhino Server. Ensure that the
pulp
user can read and write the directory and place it under/var/lib/pulp/imports/
.For more information, see Synchronizing Content Between Servers.
-
On your disconnected orcharhino Server, import your Flatpak repository:
$ hammer content-import repository \ --organization-id My_Organization_ID \ --path /var/lib/pulp/imports/My_Exported_Flatpak_Repository/
-
On your host, add the disconnected orcharhino Server as a Flatpak remote:
$ flatpak remote-add --authenticator-name=org.flatpak.Authenticator.Oci katello oci+https://orcharhino.example.com/
-
Log in using Podman:
$ podman login
-
Install your application. For example, to install the Mozilla Firefox Flatpak:
$ flatpak install firefox
The text and illustrations on this page are licensed by ATIX AG under a Creative Commons Attribution Share Alike 4.0 International ("CC BY-SA 4.0") license. This page also contains text from the official Foreman documentation which uses the same license ("CC BY-SA 4.0"). |