aks-app-routing-operator icon indicating copy to clipboard operation
aks-app-routing-operator copied to clipboard

adding custom-http-errors field to crd

Open aamgayle opened this issue 1 year ago • 2 comments

Description

These changes add access to the custom-http-errors configmap options via the CRD. This redirects the specified error codes to the default backend for handling (i.e. custom error pages)

apiVersion: 'approuting.kubernetes.azure.com/v1alpha1'
kind: NginxIngressController
metadata:
    name: custom-errors-nic
spec:
    controllerNamePrefix: nginx
    ingressClassName: nginx.approuting.kubernetes.azure.com
    defaultBackendService:
        name: example-service
        namespace: example-namespace
    customHTTPErrors:
        - 404
        - 503

Fixes # (issue) Feature # (details)

Type of change

Please delete options that are not relevant.

  • [ ] Bug fix (non-breaking change which fixes an issue)
  • [X] New feature (non-breaking change which adds functionality)
  • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • [ ] This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration. Is it a breaking change which will impact consuming tool(s)?

  • [X] Unit tests
  • [X] e2e tests

Checklist:

  • [X] My code follows the style guidelines of this project
  • [X] I have performed a self-review of my code
  • [X] I have commented my code, particularly in hard-to-understand areas
  • [X] I have made corresponding changes to the documentation
  • [X] My changes generate no new warnings
  • [X] I have added tests that prove my fix is effective or that my feature works
  • [X] New and existing unit tests pass locally with my changes
  • [X] Any dependent changes have been merged and published in downstream modules

aamgayle avatar Apr 23 '24 16:04 aamgayle

Pull Request Test Coverage Report for Build 9455033482

Details

  • 12 of 36 (33.33%) changed or added relevant lines in 3 files are covered.
  • 1 unchanged line in 1 file lost coverage.
  • Overall coverage decreased (-0.5%) to 78.693%

Changes Missing Coverage Covered Lines Changed/Added Lines %
pkg/controller/nginxingress/nginx_ingress_controller.go 4 10 40.0%
api/v1alpha1/zz_generated.deepcopy.go 2 20 10.0%
<!-- Total: 12 36
Files with Coverage Reduction New Missed Lines %
pkg/controller/ingress/concurrency_watchdog.go 1 86.41%
<!-- Total: 1
Totals Coverage Status
Change from base Build 9419625989: -0.5%
Covered Lines: 3010
Relevant Lines: 3825

💛 - Coveralls

coveralls avatar Apr 23 '24 16:04 coveralls

/ok-to-test sha=03d996c

bfoley13 avatar Aug 01 '24 16:08 bfoley13

/ok-to-test sha=77317f7

OliverMKing avatar Aug 20 '24 14:08 OliverMKing

/ok-to-test sha=b82e1c5

OliverMKing avatar Aug 20 '24 14:08 OliverMKing

/ok-to-test sha=9d210c3

OliverMKing avatar Aug 21 '24 14:08 OliverMKing

/ok-to-test sha=b8de8f4

OliverMKing avatar Aug 21 '24 20:08 OliverMKing

/ok-to-test sha=962e73c

OliverMKing avatar Aug 21 '24 20:08 OliverMKing

e2e seems to be failing due to insufficient capacity for osm

OliverMKing avatar Aug 22 '24 15:08 OliverMKing

/ok-to-test sha=2d6d210

OliverMKing avatar Aug 28 '24 17:08 OliverMKing

/ok-to-test sha=450ac11

bfoley13 avatar Sep 03 '24 16:09 bfoley13

/ok-to-test sha=6e844c3

OliverMKing avatar Sep 03 '24 17:09 OliverMKing