Skip to content

Fix nginx 1.0.0 not watching ingress without ingress class #33

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 12, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion webui/src/js/viewModels/ingress-design-view-impl.js
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,12 @@ function(i18n, accUtils, ko, ArrayDataProvider, BufferingDataProvider, project,
// if controller is Voyager and provider is baremetal only nodeport is supported, set the default in the UI
if (project.ingress.ingressControllerProvider.value === 'voyager' &&
this.project.ingress.voyagerProviderMappedValue(this.project.ingress.voyagerProvider.value) === 'baremetal') {

newRoute.annotations = {'ingress.appscode.com/type': 'NodePort'};
}
// nginx 1.0.0 and above requires setting ingressClassName either at ingress object spec level or annotation.
if (project.ingress.ingressControllerProvider.value === 'nginx') {
newRoute.annotations = {'kubernetes.io/ingress.class': 'nginx'};
}

project.ingress.ingressRoutes.addNewItem(newRoute);
};
Expand Down