Skip to content

redhat-developer/podman-desktop-sandbox-ext

Repository files navigation

Podman Desktop OpenShift Developer Sandbox Extension

This extension puts you to just few clicks away form deploying your application to OpenShift Developer Sandbox, a 30 days no cost shared cluster on OpenShift. After few simple configuration steps the extension allows you to push an image to Sandbox internal image registry, so you can create and start containers from that image in OpenShift cluster using Podman Desktop UI.

Usage

Once installed, you can find the Sandbox resource added to the Resources settings page.

1-sandbox-in-resource-settings

To configure kubernetes context for your Sandbox click on 'Create new ...' button to see Sandbox kubernetes context configuration form.

2-new-sandbox-form-annotated

Follow the description on top of the form to copy a login command from Sandbox Developer Console to Login command from Developer Console field. Then set desired kubernetes context name in corresponding field and press Create button.

3-new-sandbox-form

There should be new Sandbox connection in 'running' state in Sandbox section after that.

4-sandbox-connection-created

To deploy your first application on OpenShift. Create Containerfile shown below

FROM --platform=linux/amd64 registry.access.redhat.com/ubi8/httpd-24:latest

LABEL org.opencontainers.image.title="Simple application with static content" \
        org.opencontainers.image.description="This is example of using Apache httpd 2.4 image to deploy web server with static content" \
        org.opencontainers.image.vendor="Red Hat"

Open Podman Desktop 'Build image' page and point Containerfile path to Containerfile above. Put httpd-demo in Image Name field. Select Intel and AMD x86_64 in platform section and press 'Build' button to build the image.

5-build-image

After build is done pres Done button to swithch to Images page.

6-build-image-result

In the Images page find httpd-demo image and select item Push to Developer Sandbox cluster to tag image with Sandbox internal registry name and then push tagged image to the registry.

7-push-image-to-sandbox

After successfuly pushing the image to internal Sandbox image registry an information message with explanation should apperar.

8-push-image-to-sandbox-message

Close the message and run the image mentioned in it using run button on the right side of the image item.

9-run-built-image

In Create Container leave all default values and press Start Container button.

10-container-successfully-started

After container sucessfully started it can be deployed to kubernetes.

11-run-built-image-form

Make sure current kubernetes context is pointing to Sandbox and press Deploy button.

12-deploy-container-to-kube-form

After successful deployment application can be opened in browser.

13-deploy-container-to-kube-result

The browser window should show default test page for the running HTTPD server.

14-httpd-test-image

Installation

You can install OpenShift Developer Sandbox Extension directly from Podman Desktop Extension page.

15-installing-ext-from-catalog

Nightly Build Installation

On the Extension page press 'Install custom ...'.

image

Paste ghcr.io/redhat-developer/podman-desktop-sandbox-ext:latest to the OCI Image field and press Install button.

image