mirror of
https://github.com/portainer/portainer.git
synced 2025-07-24 15:59:41 +02:00
feat(k8s/ingresses): add more granularity to ingress configuration (#4220)
* feat(k8s/configure): separate ingress class name and ingress class type * feat(k8s/resource-pool): ability to add custom annotations to ingress classes on RP create/edit * feat(k8s/ingresses): remove 'allow users to use ingress' switch * feat(k8s/configure): minor UI update * feat(k8s/resource-pool): minor UI update * feat(k8s/application): update ingress route form validation * refactor(k8s/resource-pool): remove console.log statement * feat(k8s/resource-pool): update ingress annotation placeholders * feat(k8s/configure): add pattern form validation on ingress class * fix(k8s/resource-pool): automatically associate ingress class to ingress * fix(k8s/resource-pool): fix invalid ingress when updating a resource pool * fix(k8s/resource-pool): update ingress rewrite target annotation value * feat(k8s/application): ingress form validation * fix(k8s/application): squash ingress rules with empty host inside a single one * feat(k8s/resource-pool): ingress host validation * fix(k8s/resource-pool): rewrite rewrite option and only display it for ingress of type nginx * feat(k8s/application): do not expose ingress applications over node port * feat(k8s/application): add specific notice for ingress Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com>
This commit is contained in:
parent
68851aada4
commit
d850e18ff0
21 changed files with 699 additions and 220 deletions
|
@ -55,10 +55,10 @@ class KubernetesIngressService {
|
|||
/**
|
||||
* CREATE
|
||||
*/
|
||||
async createAsync(formValues) {
|
||||
async createAsync(ingress) {
|
||||
try {
|
||||
const params = {};
|
||||
const payload = KubernetesIngressConverter.createPayload(formValues);
|
||||
const payload = KubernetesIngressConverter.createPayload(ingress);
|
||||
const namespace = payload.metadata.namespace;
|
||||
const data = await this.KubernetesIngresses(namespace).create(params, payload).$promise;
|
||||
return data;
|
||||
|
@ -67,8 +67,8 @@ class KubernetesIngressService {
|
|||
}
|
||||
}
|
||||
|
||||
create(formValues) {
|
||||
return this.$async(this.createAsync, formValues);
|
||||
create(ingress) {
|
||||
return this.$async(this.createAsync, ingress);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -100,7 +100,7 @@ class KubernetesIngressService {
|
|||
async deleteAsync(ingress) {
|
||||
try {
|
||||
const params = new KubernetesCommonParams();
|
||||
params.id = ingress.Name;
|
||||
params.id = ingress.IngressClass.Name;
|
||||
const namespace = ingress.Namespace;
|
||||
await this.KubernetesIngresses(namespace).delete(params).$promise;
|
||||
} catch (err) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue