# Add on: Portainer

**URL:** <https://discuss.kubernetes.io/t/add-on-portainer/13714>\
**Category:** microk8s\
**Tags:** docs\
**Created:** [November 16, 2020, 3:24pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714 "2020-11-16T15:24:38Z")\
**Posts on this page:** 18\
**Page:** 1

<div class="post-metadata">

**Author:** ![kjackal](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/kjackal/32/1750_2.png) [@kjackal](https://discuss.kubernetes.io/u/kjackal)\
**Post date:** [November 16, 2020, 3:24pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/1 "2020-11-16T15:24:38Z")

</div>

Homepage: **[https://www.portainer.io/](https://www.portainer.io/)**  
From MicroK8s version: **1.20+**  
Supported arch: **amd64** , **arm64**

[Portainer](https://www.portainer.io/) allows you to “build, manage and deploy containers in your Kubernetes environment quickly and easily. No more CLI, no more YAML, no more Kubernetes manifests. Just simple, fast, K8s configuration in a graphical UI, built on a trusted open source platform.”

To enable the addon:

```auto
microk8s enable portainer

```

You will now find the Portainer exposed as a Nodeport [http service on port 30777](http://127.0.0.1:30777) and as an [https service on port 30779](http://127.0.0.1:30779). To access it remember to use the IP address or FQDN of the node MicroK8s is running on. Use localhost if you are deploying Portainer on your local workstation.

When first navigating to the URLs above, you will be asked to create a user:

 ![](https://us1.discourse-cdn.com/flex016/uploads/kubernetes/original/2X/4/4312902081f306ce74f5bb82f4a6d022021b176e.png)

Confirm the username and an 8+ character password to continue to the dashboard. This will initially open on the settings page:

 ![](https://us1.discourse-cdn.com/flex016/uploads/kubernetes/original/2X/5/5a2525b5b360877f45355ed6ceaa71c0cdac7d02.png)

For details of the settings and usage of portainer, see the [official documentation](https://documentation.portainer.io/v2.0/deploy/initial/)

## Disabling

The addon can be disabled at any time with the command:

```auto
microk8s disable portainer

```

---

<div class="post-metadata">

**Author:** ![Valentin\_Lednev](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/valentin_lednev/32/6456_2.png) [@Valentin\_Lednev](https://discuss.kubernetes.io/u/Valentin_Lednev)\
**Post date:** [December 13, 2020, 1:30pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/2 "2020-12-13T13:30:43Z")

</div>

$ microk8s enable portainer  
Nothing to do for portainer

Where is the plugin on fresh system?

---

<div class="post-metadata">

**Author:** ![evilnick](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/evilnick/32/3481_2.png) [@evilnick](https://discuss.kubernetes.io/u/evilnick)\
**Post date:** [December 14, 2020, 12:46pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/3 "2020-12-14T12:46:02Z")

</div>

Sorry portainer isn’t working for you. Some things to check:

- is MicroK8s the latest version ( `snap info microk8s` -\> v1.20.0 (1864) 219MB classic
- are you running on something other than amd64?
- are you set to the 1.20 track? `sudo snap refresh microk8s --channel=1.20`

---

<div class="post-metadata">

**Author:** ![Valentin\_Lednev](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/valentin_lednev/32/6456_2.png) [@Valentin\_Lednev](https://discuss.kubernetes.io/u/Valentin_Lednev)\
**Post date:** [December 14, 2020, 3:19pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/4 "2020-12-14T15:19:24Z")

</div>

> [@evilnick](#):
>
> sudo snap refresh microk8s --channel=1.20

Thank you very much!

---

<div class="post-metadata">

**Author:** ![haopoboy](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/haopoboy/32/6534_2.png) [@haopoboy](https://discuss.kubernetes.io/u/haopoboy)\
**Post date:** [December 22, 2020, 5:53am UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/5 "2020-12-22T05:53:34Z")

</div>

Hi,  
The URL could be 127.0.0.1:30777 with v1.20/stable on Ubuntu Server 20.04.

```auto
microk8s.kubectl get all -n portainer

NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
service/portainer NodePort 10.152.183.229 <none> 9000:30777/TCP,30776:30776/TCP 26m

```

---

<div class="post-metadata">

**Author:** ![faddat](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/faddat/32/6683_2.png) [@faddat](https://discuss.kubernetes.io/u/faddat)\
**Post date:** [January 10, 2021, 11:53am UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/6 "2021-01-10T11:53:07Z")

</div>

When you visit the portainer URL, do you get a list of API interfaces, or a UI?

I’ve yet to work out how to land on the UI.

---

<div class="post-metadata">

**Author:** ![haopoboy](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/haopoboy/32/6534_2.png) [@haopoboy](https://discuss.kubernetes.io/u/haopoboy)\
**Post date:** [January 10, 2021, 12:27pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/7 "2021-01-10T12:27:34Z")

</div>

I get an UI when I visit `127.0.0.1:30777`

---

<div class="post-metadata">

**Author:** ![balasu](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/balasu/32/3718_2.png) [@balasu](https://discuss.kubernetes.io/u/balasu)\
**Post date:** [January 12, 2021, 8:41am UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/8 "2021-01-12T08:41:32Z")

</div>

pl visit [https://documentation.portainer.io/](https://documentation.portainer.io/) to know about the features & how to deploy stack

---

<div class="post-metadata">

**Author:** ![balasu](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/balasu/32/3718_2.png) [@balasu](https://discuss.kubernetes.io/u/balasu)\
**Post date:** [January 15, 2021, 6:38am UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/9 "2021-01-15T06:38:11Z")

</div>

> [@kjackal](#):
>
> You will now find the Portainer exposed as a Nodeport [service on port 9000](http://127.0.0.1:9000)

Hi pl change the node port to 30777 in documentation,9000 is container port

---

<div class="post-metadata">

**Author:** ![notessensei](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/notessensei/32/6602_2.png) [@notessensei](https://discuss.kubernetes.io/u/notessensei)\
**Post date:** [April 22, 2021, 11:44am UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/10 "2021-04-22T11:44:10Z")

</div>

N00b advice needed:  
The microK8S instance sits behind a firewall that has only 443 and 22 open, so I can’t access Port 30777 or 9000. My understanding is, I could remedy that with an ingress definition pointing to the Portainer service. How would I design that ingress? I’m especially confused about what path to pick.

My first draft:

```auto
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: first-try
  labels:
    name: demo
  annotations:
    cert-manager.io/cluster-issuer: letsencrypt-prod
spec:
  rules:
  - host: my.web.site
    http:
      paths:
      - pathType: Prefix
        path: "/portainer"
        backend:
          service:
            name: portainer
            port:
              number: 30777          
  tls:
  - hosts:
    - my.web.page
   secretName: letsencrypt-cert   

```

Deploy this to the default namespace? There are more services that use ingress.  
Help is very much appreciated

---

<div class="post-metadata">

**Author:** ![balchua1](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/balchua1/32/5372_2.png) [@balchua1](https://discuss.kubernetes.io/u/balchua1)\
**Post date:** [April 22, 2021, 11:48am UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/11 "2021-04-22T11:48:00Z")

</div>

The ingress must be on the same namespace as the portainer `Service`.  
Try first with the root context `/` in the path.

---

<div class="post-metadata">

**Author:** ![notessensei](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/notessensei/32/6602_2.png) [@notessensei](https://discuss.kubernetes.io/u/notessensei)\
**Post date:** [April 22, 2021, 12:11pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/12 "2021-04-22T12:11:01Z")

</div>

@balchua1 Thx for chipping in. So you would suggest:

```auto
    paths:
    - pathType: Prefix
      path: "/"

```

Clashes with the landing page, but I shall try.

---

<div class="post-metadata">

**Author:** ![balchua1](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/balchua1/32/5372_2.png) [@balchua1](https://discuss.kubernetes.io/u/balchua1)\
**Post date:** [April 22, 2021, 1:15pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/13 "2021-04-22T13:15:41Z")

</div>

Sorry i misunderstood your issue.  
As i normally do is to setup a domain name like `portainer.local`, and configure ingress to route using the host rather than path. I find this easier rather than play with the path prefix.

---

<div class="post-metadata">

**Author:** ![aashu4uiit](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/aashu4uiit/32/8472_2.png) [@aashu4uiit](https://discuss.kubernetes.io/u/aashu4uiit)\
**Post date:** [August 30, 2021, 2:44am UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/14 "2021-08-30T02:44:41Z")

</div>

I am using this addon on Windows 10 using Hyper-V in which case the default URL listed for portainer is not the valid one for me as microk8s is not on localhost but on the VM inside my Hyper-V. In this case I need to run the portainer using Node’s IP address rather than localhost:

 ![image](https://us1.discourse-cdn.com/flex016/uploads/kubernetes/original/2X/b/b64aebd6776baa90bedd04ec63a612e21aa8c80f.png)

http://:30777/

---

<div class="post-metadata">

**Author:** ![Burke9077](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/burke9077/32/9219_2.png) [@Burke9077](https://discuss.kubernetes.io/u/Burke9077)\
**Post date:** [December 28, 2021, 8:32pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/15 "2021-12-28T20:32:10Z")

</div>

Thanks for enabling portainer through microk8s!

I had a question on upgrading, I’m getting a notice in the bottom right of portainer that there is a new version available. Is there any way to upgrade portainer when installed through microk8s?

I would be glad to add this to the docs if someone could point me to any resources.

---

<div class="post-metadata">

**Author:** ![evilnick](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/evilnick/32/3481_2.png) [@evilnick](https://discuss.kubernetes.io/u/evilnick)\
**Post date:** [January 7, 2022, 2:41pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/16 "2022-01-07T14:41:48Z")

</div>

I haven’t tried this yet, but I imagine it can be upgraded per the instructions on the portainer site?

```auto
microk8s kubectl apply -n portainer -f https://raw.githubusercontent.com/portainer/k8s/master/deploy/manifests/portainer/portainer.yaml

```

---

<div class="post-metadata">

**Author:** ![jamest-portainer](https://avatars.discourse-cdn.com/v4/letter/j/eb8c5e/32.png) [@jamest-portainer](https://discuss.kubernetes.io/u/jamest-portainer)\
**Post date:** [February 2, 2024, 5:02pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/17 "2024-02-02T17:02:06Z")

</div>

@kjackal, I’d like to make some changes to the Portainer MicroK8s addon.  
However, I don’t think I have enough reputation on [discuss.kubernetes.io](http://discuss.kubernetes.io) to make changes.  
Also, I see there are some ‘page version 11’ changes there which someone has made and which it would be good to also include before I make new changes.  
I want to add command line parameters and update some of the info.  
I’m a PO at Portainer.

---

<div class="post-metadata">

**Author:** ![kjackal](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.kubernetes.io/kjackal/32/1750_2.png) [@kjackal](https://discuss.kubernetes.io/u/kjackal)\
**Post date:** [February 4, 2024, 1:39pm UTC](https://discuss.kubernetes.io/t/add-on-portainer/13714/18 "2024-02-04T13:39:40Z")

</div>

Hi @jamest-portainer. Could you send me the changes you need here or on an email so I can apply them? Thanks.
