Add an Ingress using a manifest
There are two ways to add a new ingress: manually by using a form or automatically by using a manifest. This article explains how to add an ingress using a manifest.
Manifests aren't just for Ingresses - you can also deploy namespaces, ConfigMaps, secrets and volumes using a manifest.
From the menu select Ingresses then click Create from manifest.
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252F2VNZnHSWt3FfercpvYAy%252F2.16-ingress-manifest.gif%3Falt%3Dmedia%26token%3D59e340b3-bb42-4eb6-bf44-4def39059732&width=768&dpr=4&quality=100&sign=a6781c29&sv=1)
Select the namespace for your deployment, define a name for your Ingress, and then choose the build method from the options provided.
If you want to use namespaces specified in your manifest to define the namespace(s) you wish to deploy to, you can leave Namespace set to default
and toggle on the Use namespace(s) specified from manifest option.
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252FCJdC3vUXQazUFH2hSfvV%252F2.15-kubernetes_applications_add_manifest_namespace.png%3Falt%3Dmedia%26token%3Dac411131-ac8e-4a98-b7ee-5af427c3d641&width=768&dpr=4&quality=100&sign=90f3637e&sv=1)
Option 1: Git Repository
From Deployment type select either Kubernetes or Compose (depending on the format of the manifest) then enter the details of your Git repo.
Portainer uses Kompose to convert a Compose manifest to a Kubernetes-compliant manifest. This functionality is planned for deprecation in an upcoming release.
Field/Option | Overview |
---|---|
Authentication | Toggle this on if your repository requires authentication. |
Git Credentials | If the Authentication toggle is enabled and you have configured Git credentials, you can select them from this dropdown. |
Username | Enter your Git username. |
Personal Access Token | Enter your personal access token or password. |
Save credential | Check this option to save the credentials entered above for future use under the name provided in the credential name field. |
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252FKSzsXCiNjayzWdlswDGa%252F2.16-stacks-add-gitcreds.png%3Falt%3Dmedia%26token%3D5bc3782a-8c41-4096-8375-c787b2aca8b7&width=768&dpr=4&quality=100&sign=b2b59f29&sv=1)
Field/Option | Overview |
---|---|
Repository URL | Enter the repository URL. If you have enabled Authentication above the credentials will be used to access the repository. The below options will be populated by what is found in the repository. |
Repository reference | Select the reference to use when deploying the stack (for example, the branch). |
Manifest path | When using the Kubernetes deployment type, enter the path to your manifest file relative to the root of your repository. |
Compose path | When using the Compose deployment type, enter the path to your compose file relative to the root of your repository. |
Additional paths | Click add file to define additional manifests or compose files to process as part of the deployment. |
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252F72LAZ26TRcCTYAwxlM0L%252F2.16-applications-manifest-gitdetails.png%3Falt%3Dmedia%26token%3D04f5b4e9-9b22-4f67-8b3f-b06767d9d20f&width=768&dpr=4&quality=100&sign=eb66c3cb&sv=1)
Automatic updates
Enabling Automatic updates gives Portainer the ability to update your application automatically, either by polling the repository at a defined interval for changes or by using a webhook to trigger an update.
For more detail on how automatic updates function under the hood, have a look at this knowledge base article.
If your application is configured for automatic updates and you make changes locally, these changes will be overridden by the application definition in the Git repository. Bear this in mind when making configuration changes.
Field/Option | Overview |
---|---|
Mechanism | Choose from Polling or Webhook. |
Fetch interval | When using the Polling method, choose how often you wish to check the Git repository for updates to your application. |
Webhook | When using the Webhook method, this displays the webhook URL to use. Click Copy link to copy the webhook to your clipboard. |
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252FAsLjbrt9EdYoiwdlXkDf%252F2.15-k8s-applications-manifest-autoupdates-polling.png%3Falt%3Dmedia%26token%3D9456fc52-ed4f-4a29-9a37-3b5880301a29&width=768&dpr=4&quality=100&sign=41ee35f7&sv=1)
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252F7kipQ3Jsk7Nto86DwNbz%252F2.15-k8s-applications-manifest-autoupdates-webhook.png%3Falt%3Dmedia%26token%3De0361cac-50ca-4961-ac92-8d22e8c9eb81&width=768&dpr=4&quality=100&sign=135023dc&sv=1)
Field/Option | Overview |
---|---|
Force Redeployment | Enable this setting to force the redeployment of your application at the specified interval (or when the webhook is triggered), overwriting any changes that have been made in the local environment, even if there has been no update to the application in Git. This is useful if you want to ensure that your Git repository is the source of truth for your applications and are happy with the local application being replaced. If this option is left disabled, automatic updates will only trigger if Portainer detects a change in the remote Git repository. |
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252F4f5MJLBMzPQmWdE4qWUX%252F2.15-kubernetes_applications_add_manifest_force_deploy.png%3Falt%3Dmedia%26token%3Db5ef3cf9-8f89-4616-9999-bde2cf8e4042&width=768&dpr=4&quality=100&sign=7694276d&sv=1)
When you're ready, click Deploy.
Option 2: Web editor
From Deployment type select either Kubernetes or Compose (depending on the format of the manifest) then write or paste in your Kubernetes manifest.
Portainer uses Kompose to convert a Compose manifest to a Kubernetes-compliant manifest. This functionality is planned for deprecation in an upcoming release.
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252FhK226CxqRPNby6XL6p4p%252F2.16-k8s-ingress-manifest-webeditor.png%3Falt%3Dmedia%26token%3D40eab493-c738-47b3-9485-b144b7501c27&width=768&dpr=4&quality=100&sign=f3630f3b&sv=1)
You can search within the web editor at any time by pressing Ctrl-F
(or Cmd-F
on Mac).
When you're ready, click Deploy.
Option 3: URL
From Deployment type select either Kubernetes or Compose (depending on the format of the manifest) then enter the URL to your manifest file.
Portainer uses Kompose to convert a Compose manifest to a Kubernetes-compliant manifest. This functionality is planned for deprecation in an upcoming release.
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252FoWFMCnKTbSyJhxkU5gDD%252F2.15-kubernetes_applications_add_manifest_url.png%3Falt%3Dmedia%26token%3D61a60aed-1f0d-472c-aa4b-266fda945cb1&width=768&dpr=4&quality=100&sign=6a13b084&sv=1)
When you're ready, click Deploy.
Option 4: Custom template
From the Template dropdown, select the custom template to use. As an optional step, you can edit the template before deploying the application. If you have no custom templates you will be given a link to the Custom Templates section.
![](https://docs.portainer.io/~gitbook/image?url=https%3A%2F%2F3752558522-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FiZWHJxqQsgWYd9sI88sO%252Fuploads%252FeIcaSfZ4A0knbFFy6Xab%252F2.16-k8s-ingress-manifest-template.png%3Falt%3Dmedia%26token%3Df3042217-2e77-429b-94a8-00566425c1ba&width=768&dpr=4&quality=100&sign=22aa58f2&sv=1)
When you're ready, click Deploy.
Last updated