Install Podman Desktop

1
1
Send lab feedback

Install Podman Desktop

Introduction

Podman Desktop is a Graphical User Interface (GUI) for the Podman CLI, providing an easy way to interact with the Podman engine. Besides making it easy to confirm the status of the Podman engine itself, it also provides an easy way to review and interact with any containers deployed, images stored, and Podman pods and volumes on the machine. On the other hand, note that it does not provide any extra functionality unavailable from the command line.

Objectives

In this tutorial, you'll learn how to:

  • Install Podman Desktop
  • Verify basic Podman Desktop functionality works

Prerequisites

  • Minimum of a single Oracle Linux system

  • Each system should have Oracle Linux installed and configured with:

    • A Linux graphical desktop environment
    • A non-root user account with sudo access
    • Podman and cURL packages
    • Access to the Internet

Deploy Oracle Linux

Note: If running in your own tenancy, read the linux-virt-labs GitHub project README.md and complete the prerequisites before deploying the lab environment.

  1. Open a terminal on the Luna Desktop.

  2. Clone the linux-virt-labs GitHub project.

    git clone https://github.com/oracle-devrel/linux-virt-labs.git
  3. Change into the working directory.

    cd linux-virt-labs/ol
  4. Install the required collections.

    ansible-galaxy collection install -r requirements.yml
  5. Deploy the lab environment.

    ansible-playbook create_instance.yml -e localhost_python_interpreter="/usr/bin/python3.6" -e use_podman=true -e update_all=true -e use_vnc=true

    The free lab environment requires the extra variable local_python_interpreter, which sets ansible_python_interpreter for plays running on localhost. This variable is needed because the environment installs the RPM package for the Oracle Cloud Infrastructure SDK for Python, located under the python3.6 modules.

    The default deployment shape uses the AMD CPU and Oracle Linux 8. To use an Intel CPU or Oracle Linux 9, add -e instance_shape="VM.Standard3.Flex" or -e os_version="9" to the deployment command.

    Important: Wait for the playbook to run successfully and reach the pause task. At this stage of the playbook, the installation of Oracle Linux is complete, and the instances are ready. Take note of the previous play, which prints the public and private IP addresses of the nodes it deploys and any other deployment information needed while running the lab.

Access the Oracle Linux GUI Desktop Environment

  1. Open a terminal and connect via SSH to the ol-node-01 instance.

    The -L option enables local forwarding, which opens a local port to connect through an SSH tunnel to the remote VNC server.

    ssh -L 5914:localhost:5901 oracle@<ip_address_of_instance>
  2. Switch to the Luna Desktop and open the TigerVNC Viewer (Applications -> Internet -> TigerVNC Viewer).

  3. Log on to the deployed server's GUI environment by entering localhost:5914 into the VNC Server text box and press the Connect button.

    login

  4. Enter the oracle user's password of oracle and press the OK button.

    Oracle-pwd

  5. The Server's GUI desktop is displayed with a first-time login setup.

    Server-GUI

  6. Press the Next button three times, then the Skip button, followed by the Start Using Oracle Linux Server button. Finally, close or minimize the Getting Started window.

    First-time-login

Download Podman Desktop

  1. Open the Firefox browser on the remote Oracle Linux instance.

    Important: Ensure that Firefox on the remote instance is started (and NOT the Firefox browser from the Luna Desktop). In other words open the Menu called Activities and NOT the menu called Applications, otherwise the subsequent steps will not work.

    Open-Firefox

  2. Open a new browser tab and enter the following URL to navigate to the Podman Desktop Downloads location.

    https://podman-desktop.io/downloads

    Podman-Desktop-Download-

  3. Next, download the Linux version by clicking on the AMD64 binary (tar.gz) hyperlink.

  4. The file is downloaded into the Downloads directory. Click on the Show all downloads text to open the Library Manager.

    Downloads-Location

  5. Right-click on the downloaded file in the Library Manager, click on the Show in Folder menu.

  6. The File Manager opens, showing the downloaded file in the Downloads directory.

    You can double-click on the file name to expand it into a directory if it does not automatically expand.

    Expanded-File

    At this point, the Podman Desktop executable has been downloaded. The next step is to open a new Command Prompt window and then start the Podman Desktop application, so let's move on to the fun part.

Open Podman Desktop

After downloading Podman Desktop, the next step is to start it.

  1. Open a new terminal session within the VNC session displaying the ol-node-01 Linux GUI Desktop.

    Important: These steps will not work if you open a terminal on the Luna Desktop.

    Expanded-File

  2. Confirm the Podman CLI is working.

    podman run quay.io/podman/hello

    Example Output:

    Trying to pull quay.io/podman/hello:latest...
    Getting image source signatures
    Copying blob f82b04e85914 done  
    Copying config dbd85e09a1 done  
    Writing manifest to image destination
    Storing signatures
    !... Hello Podman World ...!
    
             .--"--.           
           / -     - \         
          / (O)   (O) \        
       ~~~| -=(,Y,)=- |         
        .---. /`  \   |~~      
     ~/  o  o \~~~~.----. ~~   
      | =(X)= |~  / (O (O) \   
       ~~~~~~~  ~| =(Y_)=-  |   
      ~~~~    ~~~|   U      |~~ 
    
    Project:   https://github.com/containers/podman
    Website:   https://podman.io
    Documents: https://docs.podman.io
    Twitter:   @Podman_io
  3. Change to the directory containing the Podman Desktop expanded TAR file.

    cd Downloads/podman-desktop-1.11.1/
  4. Start the Podman Desktop application.

    ./podman-desktop &>/dev/null &

    The &>/dev/null & after the podman-desktop command causes the terminal process to run in the background and not display any terminal output.

    Within the Podman Desktop application, click the Go to Podman Desktop button at the bottom right to display the default screen.

    Podman-Telemetry

An Overview of Podman Desktop

This section provides a short overview of some of the functionality offered by Podman Desktop.

  1. The Dashboard panel appears and shows the version of Podman currently installed on the system.

    Podman-Start

  2. The Settings section shows some of the options available to alter some of Podman Desktop's behavior.

    Click the gear-shaped icon at the bottom of the left-hand navigation menu bar to review what can be changed.

    Podman-Settings

  3. Click the Settings button again to return to the Dashboard panel.

  4. Click the Images menu to review the container images present on the system.

    This panel lists all container images that have been pulled to this machine. It currently shows the quay.io/podman/hello image that was pulled at the start of this tutorial. It does not represent containers that are, or have been, started.

    Podman-Images

    Use the buttons in the upper right corner of the Images panel to:

    • Prune - removes unused images.
    • Load - load an image from Tar archives.
    • Import - imports a container from the filesystem.
    • Pull - pulls a container from a Registry.
    • Build - used to build a containerfile.
  5. Click the quay.io/podman/hello image to review more detailed information about the container image.

    The tabs represent, in turn:

    • Summary - The image ID, size, and creation date information.
    • History - Shows information about the layers used to create the container image.
    • Inspect - Shows low-level information about the container in a JSON format.

    Podman-ImageDetail

  6. Next, click the Containers menu to review any running or stopped containers.

    Podman-Telemetry

  7. The Containers panel shows information for the quay.io/podman/hello image pulled at the start of this tutorial.

    1. Click the randomly assigned name for the deployed container.

    2. Click the Logs tab and notice the Logs output seen earlier when running Podman on the command line.

    3. Click on the other menu options (Logs, Inspect, Kube, Terminal) to review other information available via the Podman Desktop GUI.

    Podman-ContainerDetails

    Because the quay.io/podman/hello container has exited or stopped running, the Terminal tab will not provide access to the container's runtime environment.

  8. To return to the Dashboard panel, click on the Dashboard menu item at the top of the navigation menu on the left.

    Podman-Dashboard

  9. Feel free to click on the Pods and the Volumes navigational menu items.

    Nothing will be displayed for these features because no Podman pods or volumes exist on this system.

    That concludes our brief overview of installing and navigating the Podman Desktop GUI interface. For more in-depth information describing Podman Desktop's functionality, please refer to the Podman Desktop documentation located here .

    The following section provides a simple walkthrough of how to use the Podman Desktop GUI to pull and run an Nginx image.

(Optional) Pull and Run Nginx using Podman Desktop

The following steps provide a simple walkthrough outlining how to pull and run an image - in this example, Nginx.

  1. Click the Images navigational menu to review the container images present on the system.

    Podman-Images

  2. Click the Pull button.

    Then, enter ghcr.io/oracle/oraclelinux8-nginx:1.20 into the Image to Pull text box.

    Podman-pull-nginx

  3. Click the Pull Image button to start the download.

    The Nginx image has now been pulled to the local machine and is available to run as a container.

  4. Click the Images navigational menu again to display the available Nginx image.

    Under Actions, click the Run Image button

    Podman-nginx-run

  5. The Run image dialogue box opens, allowing the container's runtime settings to be modified or accept the defaults.

    Accept the defaults and press the Start Container button.

    Podman-nginx-run

    Note: If you get an error about a rootlessport conflict, then update the default port mappings from 9000 to 9443 for 443/tcp or HTTPS and 9080 for 80/tcp or HTTP.

  6. Podman Desktop automatically switches to the Container Details panel.

    Podman-nginx-run

  7. In the upper right corner of the Container Details panel, click the Open Browser button.

    Podman-nginx-run

  8. A browser opens and displays the Welcome to Nginx! message.

    Podman-nginx-run

Next Steps

This completes the demonstration showing how to use Podman Desktop to download and then start a Podman container - in this example, Nginx.

In the meantime, many thanks for taking the time to try this tutorial.

SSR