application-gateway-kubernetes-ingress icon indicating copy to clipboard operation
application-gateway-kubernetes-ingress copied to clipboard

Unable to use AGIC with multi namespaces

Open ishankush01 opened this issue 2 years ago • 1 comments

I am unable to install AGIC with either a watchNamespace: "" or a blank namespace. code for blow

`# This file contains the essential configs for the ingress controller helm chart

# Verbosity level of the App Gateway Ingress Controller
verbosityLevel: 3

################################################################################
# Specify which application gateway the ingress controller will manage
#
appgw:
    subscriptionId: 00000000-0000-0000-0000-000000000000
    resourceGroup: my-resource-group
    name: my-test-appgw
    usePrivateIP: false

    # Setting appgw.shared to "true" will create an AzureIngressProhibitedTarget CRD.
    # This prohibits AGIC from applying config for any host/path.
    # Use "kubectl get AzureIngressProhibitedTargets" to view and change this.
    shared: false

################################################################################
# Specify which kubernetes namespace the ingress controller will watch
# Default value is "default"
# Leaving this variable out or setting it to blank or empty string would
# result in Ingress Controller observing all acessible namespaces.
#
# kubernetes:
#     watchNamespace: 

################################################################################
# Specify the authentication with Azure Resource Manager
#
# Two authentication methods are available:
# - Option 1: AAD-Pod-Identity (https://github.com/Azure/aad-pod-identity)
armAuth:
    type: aadPodIdentity
    identityResourceID: *********************************
    identityClientID:  00000000-0000-0000-0000-000000000000

## Alternatively you can use Service Principal credentials
#armAuth:
 #   type: servicePrincipal
 #   secretJSON: 
################################################################################
# Specify if the cluster is RBAC enabled or not
rbac:
    enabled: true # true/false`

It shows an error

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x1375dcf]

I'm attempting to use it with a different namespace, but when I specify 'main' for the 'watchNamespace' property, it functions as intended. However, in this case, I am unable to use it with a different namespace.

Would you accept contributions if we are willing to implement this feature?

ishankush01 avatar May 27 '23 17:05 ishankush01

You can provide multiple namespaces comma separated.

akshaysngupta avatar Aug 01 '23 20:08 akshaysngupta