2024-09-27 04:39:44 +00:00
<!doctype html>
< html lang = "en" dir = "ltr" class = "docs-wrapper plugin-docs plugin-id-tutorial docs-version-current docs-doc-page docs-doc-id-deploying-a-kubernetes-application" data-has-hydrated = "false" >
< head >
< meta charset = "UTF-8" >
2025-01-14 13:36:07 +00:00
< meta name = "generator" content = "Docusaurus v3.7.0" >
2024-09-27 04:39:44 +00:00
< title data-rh = "true" > Deploying a Kubernetes application | Podman Desktop< / title > < meta data-rh = "true" name = "viewport" content = "width=device-width,initial-scale=1" > < meta data-rh = "true" name = "twitter:card" content = "summary_large_image" > < meta data-rh = "true" property = "og:image" content = "https://podman-desktop.io/img/banner_podman-desktop.png" > < meta data-rh = "true" name = "twitter:image" content = "https://podman-desktop.io/img/banner_podman-desktop.png" > < meta data-rh = "true" property = "og:url" content = "https://podman-desktop.io/tutorial/deploying-a-kubernetes-application" > < meta data-rh = "true" property = "og:locale" content = "en" > < meta data-rh = "true" name = "docusaurus_locale" content = "en" > < meta data-rh = "true" name = "docsearch:language" content = "en" > < meta data-rh = "true" name = "docusaurus_version" content = "current" > < meta data-rh = "true" name = "docusaurus_tag" content = "docs-tutorial-current" > < meta data-rh = "true" name = "docsearch:version" content = "current" > < meta data-rh = "true" name = "docsearch:docusaurus_tag" content = "docs-tutorial-current" > < meta data-rh = "true" property = "og:title" content = "Deploying a Kubernetes application | Podman Desktop" > < meta data-rh = "true" name = "description" content = "Deploying a Kubernetes application" > < meta data-rh = "true" property = "og:description" content = "Deploying a Kubernetes application" > < meta data-rh = "true" name = "keywords" content = "podman desktop,podman,Kubernetes" > < link data-rh = "true" rel = "icon" href = "/img/favicon.ico" > < link data-rh = "true" rel = "canonical" href = "https://podman-desktop.io/tutorial/deploying-a-kubernetes-application" > < link data-rh = "true" rel = "alternate" href = "https://podman-desktop.io/tutorial/deploying-a-kubernetes-application" hreflang = "en" > < link data-rh = "true" rel = "alternate" href = "https://podman-desktop.io/tutorial/deploying-a-kubernetes-application" hreflang = "x-default" > < link data-rh = "true" rel = "preconnect" href = "https://MR01ANKQ9S-dsn.algolia.net" crossorigin = "anonymous" > < link rel = "alternate" type = "application/rss+xml" href = "/blog/rss.xml" title = "Podman Desktop RSS Feed" >
< link rel = "alternate" type = "application/atom+xml" href = "/blog/atom.xml" title = "Podman Desktop Atom Feed" >
< link rel = "alternate" type = "application/json" href = "/blog/feed.json" title = "Podman Desktop JSON Feed" >
2025-01-14 13:36:07 +00:00
2024-09-27 04:39:44 +00:00
< link rel = "search" type = "application/opensearchdescription+xml" title = "Podman Desktop" href = "/opensearch.xml" >
< link rel = "preconnect" href = "https://podman-desktop-website.goatcounter.com" >
2025-03-12 19:03:03 +00:00
< script async src = "//gc.zgo.at/count.js" data-goatcounter = "https://podman-desktop-website.goatcounter.com/count" > < / script > < link rel = "stylesheet" href = "/assets/css/styles.4e28e39a.css" >
2025-03-19 09:20:43 +00:00
< script src = "/assets/js/runtime~main.613a1017.js" defer = "defer" > < / script >
2025-03-17 09:57:37 +00:00
< script src = "/assets/js/main.3d5cf59f.js" defer = "defer" > < / script >
2024-09-27 04:39:44 +00:00
< / head >
< body class = "navigation-with-keyboard" >
2025-03-05 15:24:15 +00:00
< script > ! function ( ) { function t ( t ) { document . documentElement . setAttribute ( "data-theme" , t ) } var e = function ( ) { try { return new URLSearchParams ( window . location . search ) . get ( "docusaurus-theme" ) } catch ( t ) { } } ( ) || function ( ) { try { return window . localStorage . getItem ( "theme" ) } catch ( t ) { } } ( ) ; null !== e ? t ( e ) : window . matchMedia ( "(prefers-color-scheme: dark)" ) . matches ? t ( "dark" ) : window . matchMedia ( "(prefers-color-scheme: light)" ) . matches ? t ( "light" ) : t ( "dark" ) } ( ) , function ( ) { try { const c = new URLSearchParams ( window . location . search ) . entries ( ) ; for ( var [ t , e ] of c ) if ( t . startsWith ( "docusaurus-data-" ) ) { var a = t . replace ( "docusaurus-data-" , "data-" ) ; document . documentElement . setAttribute ( a , e ) } } catch ( t ) { } } ( ) < / script > < div id = "__docusaurus" > < div role = "region" aria-label = "Skip to main content" > < a class = "skipToContent_oPtH" href = "#__docusaurus_skipToContent_fallback" > Skip to main content< / a > < / div > < nav aria-label = "Main" class = "navbar navbar--fixed-top" > < div class = "navbar__inner" > < div class = "navbar__items" > < button aria-label = "Toggle navigation bar" aria-expanded = "false" class = "navbar__toggle clean-btn" type = "button" > < svg width = "30" height = "30" viewBox = "0 0 30 30" aria-hidden = "true" > < path stroke = "currentColor" stroke-linecap = "round" stroke-miterlimit = "10" stroke-width = "2" d = "M4 7h22M4 15h22M4 23h22" > < / path > < / svg > < / button > < a class = "navbar__brand" href = "/" > < div class = "navbar__logo" > < img src = "/img/logo.svg" alt = "Podman Desktop Logo" class = "themedComponent_siVc themedComponent--light_hHel" height = "56" > < img src = "/img/logo.svg" alt = "Podman Desktop Logo" class = "themedComponent_siVc themedComponent--dark_yETr" height = "56" > < / div > < b class = "navbar__title text--truncate" > podman desktop< / b > < / a > < a class = "navbar__item navbar__link" href = "/docs/intro" > Documentation< / a > < a class = "navbar__item navbar__link" href = "/downloads" > Downloads< / a > < a class = "navbar__item navbar__link" href = "/community" > Community< / a > < div class = "navbar__item dropdown dropdown--hoverable" > < a href = "#" aria-haspopup = "true" aria-expanded = "false" role = "button" class = "navbar__link" > Resources< / a > < ul class = "dropdown__menu" > < li > < a class = "dropdown__link" href = "/features" > Features< / a > < / li > < li > < a aria-current = "page" class = "dropdown__link dropdown__link--active" href = "/tutorial" > Tutorials< / a > < / li > < li > < a class = "dropdown__link" href = "/extend" > Extend< / a > < / li > < / ul > < / div > < a class = "navbar__item navbar__link" href = "/blog" > Blog< / a > < / div > < div class = "navbar__items navbar__items--right" > < a href = "https://github.com/podman-desktop/podman-desktop" target = "_blank" rel = "noopener noreferrer" class = "navbar__item navbar__link header-github-link" > < / a > < div class = "toggle_ki11 colorModeToggle_Hewu" > < button class = "clean-btn toggleButton_MMFG toggleButtonDisabled_Uw7m" type = "button" disabled = "" title = "Switch between dark and light mode (currently dark mode)" aria-label = "Switch between dark and light mode (currently dark mode)" aria-live = "polite" aria-pressed = "true" > < svg viewBox = "0 0 24 24" width = "24" height = "24" class = "lightToggleIcon_lgto" > < path fill = "currentColor" d = "M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z" > < / path > < / svg > < svg viewBox = "0 0 24 24" width = "24" height = "24" class = "darkToggleIcon_U96C" > < path fill = "currentColor"
2024-09-27 04:39:44 +00:00
< p > This tutorial covers the following end-to-end tasks required to deploy an application in a Kubernetes cluster:< / p >
< ul >
< li > Set the Kubernetes context< / li >
< li > Creating a deployment< / li >
< li > Creating a service< / li >
< li > Verifying the service: port forwarding< / li >
< / ul >
< p > If you have multiple Kubernetes contexts, you must set the correct context in which you want to create your application resources. Within a Kubernetes cluster, you can access the application by its internal IP address. However, if you want to make your application accessible from an outside network, you must expose the pod containing your application as a Kubernetes service.
To access the service running on your Kubernetes cluster, you can use one of the following options:< / p >
< ul >
2024-11-21 10:03:00 +00:00
< li > Configure port forwarding< / li >
< li > < a href = "/docs/kind/building-an-image-and-testing-it-in-kind" > Create an ingress controller< / a > < / li >
2024-09-27 04:39:44 +00:00
< / ul >
< h2 class = "anchor anchorWithStickyNavbar_JmGV" id = "before-you-begin" > Before you begin< a href = "#before-you-begin" class = "hash-link" aria-label = "Direct link to Before you begin" title = "Direct link to Before you begin" > < / a > < / h2 >
< p > Make sure you have:< / p >
< ul >
< li > < a href = "/docs/installation" > Installed Podman Desktop< / a > .< / li >
< li > < a href = "/docs/podman/creating-a-podman-machine" > A running Podman machine< / a > .< / li >
< li > < a href = "/docs/kind/creating-a-kind-cluster" > A running Kubernetes cluster< / a > .< / li >
< li > A developer role.< / li >
< li > Created a < code > Deployment< / code > file using the following code, if you do not have one on your machine:< / li >
< / ul >
< div class = "language-yaml codeBlockContainer_mQmQ theme-code-block" style = "--prism-color:#F8F8F2;--prism-background-color:#282A36" > < div class = "codeBlockContent_D5yF" > < pre tabindex = "0" class = "prism-code language-yaml codeBlock_RMoD thin-scrollbar" style = "color:#F8F8F2;background-color:#282A36" > < code class = "codeBlockLines_AclH" > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token key atrule" > apiVersion< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > apps/v1< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > kind< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > Deployment< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > metadata< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > name< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > my< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > -< / span > < span class = "token plain" > nginx< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > spec< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > selector< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > matchLabels< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > run< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > my< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > -< / span > < span class = "token plain" > nginx< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > replicas< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < span class = "token number" > 2< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > template< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > metadata< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > labels< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > run< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > my< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > -< / span > < span class = "token plain" > nginx< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > spec< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< /
< p > This YAML configuration creates a < code > my-nginx< / code > deployment running two Nginx pods.< / p >
< ul >
< li > Created a < code > Service< / code > file using the following code, if you do not have one on your machine:< / li >
< / ul >
< div class = "language-yaml codeBlockContainer_mQmQ theme-code-block" style = "--prism-color:#F8F8F2;--prism-background-color:#282A36" > < div class = "codeBlockContent_D5yF" > < pre tabindex = "0" class = "prism-code language-yaml codeBlock_RMoD thin-scrollbar" style = "color:#F8F8F2;background-color:#282A36" > < code class = "codeBlockLines_AclH" > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token key atrule" > apiVersion< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > v1< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > kind< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > Service< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > metadata< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > name< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > my< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > -< / span > < span class = "token plain" > nginx< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > labels< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > run< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > my< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > -< / span > < span class = "token plain" > nginx< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > spec< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > ports< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > -< / span > < span class = "token plain" > < / span > < span class = "token key atrule" > port< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < span class = "token number" > 80< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > protocol< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > TCP< / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > targetPort< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < span class = "token number" > 80< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > selector< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > < / span > < br > < / span > < span class = "token-line" style = "color:#F8F8F2" > < span class = "token plain" > < / span > < span class = "token key atrule" > run< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > :< / span > < span class = "token plain" > my< / span > < span class = "token punctuation" style = "color:rgb(248, 248, 242)" > -< / span > < span class = "token plain" > nginx< / span > < br > < / span > < / code > < / pre > < div class = "buttonG
< p > This YAML configuration creates a service named < code > my-nginx< / code > to expose the Nginx deployment outside the Kubernetes cluster. The service listens client requests on port < code > 80< / code > and then forwards them to a target port < code > 80< / code > on the container.< / p >
< h2 class = "anchor anchorWithStickyNavbar_JmGV" id = "setting-the-kubernetes-context" > Setting the Kubernetes context< a href = "#setting-the-kubernetes-context" class = "hash-link" aria-label = "Direct link to Setting the Kubernetes context" title = "Direct link to Setting the Kubernetes context" > < / a > < / h2 >
< ol >
< li > Go to < strong > Settings > Kubernetes< / strong > .< / li >
< li > Set the current Kubernetes context. For example, if you want to use a Kind cluster, use the < strong > Set as Current Context< / strong > icon in the UI:
< img decoding = "async" loading = "lazy" alt = "setting context" src = "/assets/images/setting-context-7aef9cd6ba2fe344daf92d8d8e7c2c8f.png" width = "988" height = "517" class = "img_SS3x" > < / li >
< / ol >
< h2 class = "anchor anchorWithStickyNavbar_JmGV" id = "creating-a-deployment" > Creating a deployment< a href = "#creating-a-deployment" class = "hash-link" aria-label = "Direct link to Creating a deployment" title = "Direct link to Creating a deployment" > < / a > < / h2 >
< ol >
< li > Go to Kubernetes explorer from the left navigation pane.< / li >
< li > Go to < strong > Deployments< / strong > and Click < strong > Apply YAML< / strong > .
< img decoding = "async" loading = "lazy" alt = "apply deployment yaml" src = "/assets/images/apply-deployment-yaml-76d1451f4232c9bdd950c302c285930a.png" width = "983" height = "184" class = "img_SS3x" > < / li >
< li > Select the YAML configuration file and click < strong > Open< / strong > . A successful operation notification opens.
< img decoding = "async" loading = "lazy" alt = "notification" src = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAf0AAAC1CAYAAABVsCY9AAAACXBIWXMAAA7EAAAOxAGVKw4bAAAdWklEQVR4nO3dd3RUdf7/8WcmM5NJSDK0BEIJkNBDr4vltwqKDWGxfb9ARAFFRUUXAQvg4uq6KCwiiBRBASmKuhrgi4Iigg1EViBBQgsQEloCpJFMpv7+iMwSE0ogIcJ9Pc7xHO6de+/nfT85x9d8PrdMQEREhC8v7xTBwcE0atSQX3/dQUxMLCdOHCcrKwubzUZs41i2J21HKo7ZbMZmC6nsMv4QHI583G53sXXqn7IrrR9FxNhMlV2AFHG73fofNOB2u0rtB/VP2ZytH0XE2EwQUNk1yG+cTgfgq+wyKo3P56Ow0HHWz43ePxfqfP0oIsZlttvt5OXlYbaYz1jtxWQqmgTweDxYLJbKqc5gvF4veXm5mM0WzGYzJlOg/+9wtfJ6vXi9nt9G8q7zbmu0/rlQZelHETEuc0RETWrUqE5+gQPfb4Oo48dPEN0gGpfLRW5uLlkns4mLi+PQoUO4XB6Cg0MIDg7BbNaXARERkcvN7XZRUJCPw5FPQcGF378TEBwcct75UpstmNq16xEcHILTWYjL5cLlKsTj8Vxy4SIiIlI2gYFmLBYrVmvRf/n5+Rw+fPC8l/bOG/q1atXBbq9GZuZRhbyIiMgfUGBgIBERtcnKOsHRo4fOut05Q79p0zgKCvLJycmqkCJFRESk/ISHV8VmC2b37l9L/fysod+kSRxZWcdxOgsrtEAREREpP0FBNqpWrc6uXSXfr1Nq6Ner1xCfr+hOaREREbmyhIaGA5CefqDY+hLPO1WpEobNFqzAFxERuULl5eUQElKFKlVCi60vEfp16kSTmXn0shU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crkAqFOnDmlp6QQEBJS6/+mb5mw2G/Xr1yMjIxO3282RI0cAmDNnLh999MlF1fZ7mZnHcblc5ObmMnjwwxQUFJTYxucDq/W/3+xOT9X/9NNPjBs3vsT2KSkpjBs3nuDgYG688QaeeupJ7rqrLxMmvF4uNYuISMWqWrUqderUYdGiJf4B265du1m0aAn33XcPdru9XG/mq7DQT0tLZ/z4lxg79gVatGhOrVq1iItrCRSF8bFjx+jQoT0vvvjSJb2Zb9q06TRt2pROnTrSv///smjREnbv3gPAqFEj2bx5Mx07dix135EjR/Dtt9/TqlVLrFYrK1b8HwCrVq2mb9+/EB8/gFq1apOSkkKDBtEkJCwvdXR/ITweDwkJy7nnnruYMOEfrF//LSZTIF6vh08++RSA9PR0YmIacf/98WzblkhSUhLJycl06dKFsWNfYMuWLdSoUZPk5GQ2bvyJJ54YRlhYGLt376ZJkyYAZGRkXFR9IiJy+WVlZZU68N25c9dFD4jPpUJfzpOYmMSQIUNxOp3ExsaQlZVFbm4usbExOJ1OhgwZyq+//npJbRQWFvLqqxNwOAqJjx9A+/btWL36S774YhWBgSaaNWvK++8v5NSpU8X2O3gwjf/85xduueVmqlWrxsKFi1i69CMAMjIyGTFiFFu2bOX666/lgQcGUq9ePWrUqH5Jtb777nu8884cgoODGTjwfnr0uNF/KQHgzTensW/fPu655y569rwJj8fDiy+OZ8WKlTRp0pghQwbTrl1batYsegGR2+2mefNmPPDAQNq2bcMXX6wqdn+BiIjImQLCwsL8d9a1aNGO1NSy31R3oRo0aIDb7SI9/eJGyyIiIlI20dEx7NixBbhMP7hz2oEDBy5ncyIiInIG/bSuiIiIQSj0RUREDEKhLyIiYhAKfREREYNQ6IuIiBiEQl9ERMQgFPoi
< li > Click < strong > OK< / strong > .< / li >
< li > View the newly created < code > my-nginx< / code > deployment on the same page.
< img decoding = "async" loading = "lazy" alt = "new deployment" src = "/assets/images/new-deployment-85092735bdb930e050d9269a26ad4361.png" width = "990" height = "234" class = "img_SS3x" > < / li >
< li > Restart the Podman Desktop application.< / li >
< li > Go to < strong > Pods< / strong > from the left navigation pane.< / li >
< li > View the two newly created < code > my-nginx< / code > pods.
< img decoding = "async" loading = "lazy" alt = "new running pods" src = "/assets/images/running-pods-15e20c6ca5078bb97453658700a3771e.png" width = "977" height = "371" class = "img_SS3x" > < / li >
< / ol >
< h2 class = "anchor anchorWithStickyNavbar_JmGV" id = "creating-a-service" > Creating a service< a href = "#creating-a-service" class = "hash-link" aria-label = "Direct link to Creating a service" title = "Direct link to Creating a service" > < / a > < / h2 >
< ol >
< li > In the Kubernetes explorer, go to < strong > Services< / strong > .< / li >
< li > Click < strong > Apply YAML< / strong > .< / li >
< li > Select the YAML configuration file and click < strong > Open< / strong > . A successful operation notification opens.< / li >
< li > Click < strong > OK< / strong > .< / li >
< li > View the newly created service on the same page.
2024-11-21 10:03:00 +00:00
< img decoding = "async" loading = "lazy" alt = "new service object" src = "/assets/images/new-service-object-a3ad16ab49a399e4ebdbeecfe1a96e13.png" width = "1534" height = "464" class = "img_SS3x" > < / li >
2024-09-27 04:39:44 +00:00
< / ol >
< h2 class = "anchor anchorWithStickyNavbar_JmGV" id = "verifying-the-service-port-forwarding" > Verifying the service: port forwarding< a href = "#verifying-the-service-port-forwarding" class = "hash-link" aria-label = "Direct link to Verifying the service: port forwarding" title = "Direct link to Verifying the service: port forwarding" > < / a > < / h2 >
< ol >
2024-11-21 10:03:00 +00:00
< li > In the Kubernetes explorer, go to < strong > Services< / strong > .< / li >
< li > Click the name of the < code > my-nginx< / code > service.< / li >
< li > Click < strong > Forward...< / strong > .
< img decoding = "async" loading = "lazy" alt = "forward button" src = "/assets/images/forward-button-2fc0dacd5cb17306353f4b560904c97b.png" width = "1450" height = "818" class = "img_SS3x" > < / li >
< li > Click < strong > Open< / strong > to view the Nginx welcome page in a web browser.
< img decoding = "async" loading = "lazy" alt = "welcome page" src = "/assets/images/welcome-page-6b899929eb5b581ad046b89aad7cf188.png" width = "1302" height = "556" class = "img_SS3x" > < / li >
2025-03-14 07:23:01 +00:00
< / ol > < / div > < footer class = "theme-doc-footer docusaurus-mt-lg" > < div class = "row margin-top--sm theme-doc-footer-tags-row" > < div class = "col" > < b > Tags:< / b > < ul class = "tags_Ow0B padding--none margin-left--sm" > < li class = "tag_DFxh" > < a class = "tag_otG2 tagRegular_s0E1" href = "/tutorial/tags/podman-desktop" > podman-desktop< / a > < / li > < li class = "tag_DFxh" > < a class = "tag_otG2 tagRegular_s0E1" href = "/tutorial/tags/deploying-a-kubernetes-application" > deploying-a-kubernetes-application< / a > < / li > < / ul > < / div > < / div > < / footer > < / article > < nav class = "pagination-nav docusaurus-mt-lg" aria-label = "Docs pages" > < a class = "pagination-nav__link pagination-nav__link--prev" href = "/tutorial/running-a-kubernetes-cluster" > < div class = "pagination-nav__sublabel" > Previous< / div > < div class = "pagination-nav__label" > Running a Kubernetes cluster< / div > < / a > < a class = "pagination-nav__link pagination-nav__link--next" href = "/tutorial/interacting-with-a-database-server" > < div class = "pagination-nav__sublabel" > Next< / div > < div class = "pagination-nav__label" > Interacting with a database server< / div > < / a > < / nav > < / div > < / div > < div class = "col col--3" > < div class = "tableOfContents_XG6w thin-scrollbar theme-doc-toc-desktop" > < ul class = "table-of-contents table-of-contents__left-border" > < li > < a href = "#before-you-begin" class = "table-of-contents__link toc-highlight" > Before you begin< / a > < / li > < li > < a href = "#setting-the-kubernetes-context" class = "table-of-contents__link toc-highlight" > Setting the Kubernetes context< / a > < / li > < li > < a href = "#creating-a-deployment" class = "table-of-contents__link toc-highlight" > Creating a deployment< / a > < / li > < li > < a href = "#creating-a-service" class = "table-of-contents__link toc-highlight" > Creating a service< / a > < / li > < li > < a href = "#verifying-the-service-port-forwarding" class = "table-of-contents__link toc-highlight" > Verifying the service: port forwarding< / a > < / li > < / ul > < / div > < / div > < / div > < / div > < / main > < / div > < / div > < / div > < footer class = "footer" > < div class = "container container-fluid" > < div class = "row footer__links" > < div class = "col footer__col" > < div class = "footer__title" > Documentation< / div > < ul class = "footer__items clean-list" > < li class = "footer__item" > < a class = "footer__link-item" href = "/docs/installation" > Installing Podman Desktop< / a > < / li > < li class = "footer__item" > < a class = "footer__link-item" href = "/docs/migrating-from-docker" > Migrating from Docker< / a > < / li > < li class = "footer__item" > < a class = "footer__link-item" href = "/docs/kubernetes" > Working with Kubernetes< / a > < / li > < li class = "footer__item" > < a class = "footer__link-item" href = "/docs/troubleshooting" > Troubleshooting< / a > < / li > < / ul > < / div > < div class = "col footer__col" > < div class = "footer__title" > Links< / div > < ul class = "footer__items clean-list" > < li class = "footer__item" > < a href = "https://github.com/podman-desktop/podman-desktop" target = "_blank" rel = "noopener noreferrer" class = "footer__link-item" > GitHub< svg width = "13.5" height = "13.5" aria-hidden = "true" viewBox = "0 0 24 24" class = "iconExternalLink_nPrP" > < path fill = "currentColor" d = "M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z" > < / path > < / svg > < / a > < / li > < li class = "footer__item" > < a href = "https://discord.com/invite/x5GzFF6QH4" target = "_blank" rel = "noopener noreferrer" class = "footer__link-item" > Chat (bridged): #podman-desktop on Discord< svg width = "13.5" height = "13.5" aria-hidden = "true" viewBox = "0 0 24 24" class = "iconExternalLink_nPrP" > < path fill = "currentColor" d = "M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z" > < / path > < / svg > < / a > < / li > < li class = "footer__item" > < a href = "https://github.com/podman-desktop/podman-desktop#communication" target = "_blank" rel = "noopener noreferrer" class = "footer__link-item" > Other ways to Communicate< svg width = "13.5" height = "13.5" aria-hidden = "true" viewBox = "0 0 24 24" class = "iconExternalLink_nPrP" > < path fill = "currentColor" d = "M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z" > < / path > < / svg > < / a > < / li > < li class = "footer__item" > < a href = "https://github.com/orgs/podman-desktop/projects/4/views/3" target = "_blank" rel = "noopener nor
2025-01-29 20:58:29 +00:00
< div class = "w-80" > < img class = "dark:hidden" alt = "Cloud Native Computing Foundation" src = "/img/cncf-logo.svg" > < img class = "hidden dark:inline" alt = "Cloud Native Computing Foundation" src = "/img/cncf-logo-dark.svg" > < / div >
< div > We are a < a href = "https://cncf.io/" > Cloud Native Computing Foundation< / a > sandbox project.< / div >
< div class = "text-sm" >
© Copyright podman desktop Contributors 2025. © 2025 The Linux Foundation. All rights reserved.
< / div >
< div class = "text-xs" > The Linux Foundation has registered trademarks and uses trademarks. For a list of trademarks of The Linux Foundation, please see our < a href = "https://www.linuxfoundation.org/trademark-usage/" > Trademark Usage< / a > page.
< / div >
< / div > < / div > < / div > < / div > < / footer > < / div >
2024-09-27 04:39:44 +00:00
< / body >
< / html >