Deploy with UDS Core
Sample Application with UDS Core
This tutorial uses UDS CLI to deploy an example application, podinfo, on top of UDS Core as a UDS Bundle.
Prerequisites
Quickstart
To begin, a Zarf Package needs to be created for podinfo
. See the Zarf documentation for in-depth information on how to create a Zarf Package, or simply use the information provided below.
Make a Directory
Make a new directory for this package using the following command:
Create the following zarf.yaml
in the new directory:
Create the Zarf Package
Run the following command in the same directory as the above zarf.yaml
. This will create a Zarf Package named zarf-package-podinfo-<arch>-0.0.1.tar.zst
:
Create the UDS Bundle
Create the UDS Bundle in the same directory as the package
directory. The following bundle includes:
- k3d cluster:
uds-k3d
. - Zarf init package:
init
. - UDS Core:
core
. - Locally built example application:
podinfo
.
Create the following uds-bundle.yaml
:
UDS Bundles can easily be configured to include additional applications and capabilities. For example, if you would like to deploy dos-games instead of podinfo
, in the uds-bundle.yaml
simply replace:
with:
Create and Confirm the UDS Bundle
This process will take a few minutes while UDS CLI pulls down the images that will be deployed. This command will produce a UDS Bundle named uds-bundle-podinfo-bundle-<arch>-0.0.1.tar.zst
:
Deploy
You can now deploy the bundle to create the k3d cluster in order to deploy UDS Core and podinfo
. This process will take approximately 5 to 10 minutes to complete:
Interact with Cluster (Optional)
Once successfully deployed, you have the option interact with the deployed cluster and applications using kubectl or k9s. Please note that the output for your podinfo
pod will likely have a different name:
Connect to podinfo
using kubectl port-forward
:
Example command using the above sample output from get pods
:
You can now use a web browser to naviage to http://localhost:<local_port>
to interact with podinfo
.
Clean up
Execute the following command to clean up your cluster: