ansible/awx

CORS errors after upgrading to AWX 22.3.0

Open

#14.024 aperta il 18 mag 2023

Vedi su GitHub
 (20 commenti) (0 reazioni) (0 assegnatari)Python (3333 fork)batch import
communityhelp wantedtype:bug

Metriche repository

Star
 (13.071 star)
Metriche merge PR
 (Merge medio 24g 6h) (30 PR mergiate in 30 g)

Descrizione

Please confirm the following

  • I agree to follow this project's code of conduct.
  • I have checked the current issues for duplicates.
  • I understand that the AWX Operator is open source software provided for free and that I might not receive a timely response.

Bug Summary

We have an external load balancer in from of our kubernetes based install that terminates SSL, and passes it to the host. URL configured for ingress on external load balancer: https://vip.example.com backend server load balancer sends traffic to (the kubernetes node): http://awx.example.com:30080 After upgrading from version 21.x, we are now seeing the following error: POST api/v2/job_templates/31/launch/ 403 CSRF Failed: Origin checking failed - https://vip.example.com does not match any trusted origins. As a work-around we are using http://awx.example.com:30080 URL to login.

AWX Operator version

2.2.1

AWX version

22.3.0

Kubernetes platform

kubernetes

Kubernetes/Platform version

Major:"1", Minor:"25"

Modifications

no

Steps to reproduce

awx.yaml file I deployed with:

apiVersion: awx.ansible.com/v1beta1 kind: AWX metadata: name: awx-kubernetes spec: service_type: nodeport

Expected results

Expect to allow CORS headers

Actual results

giving error. Even tried updating the awx.yaml with:

apiVersion: awx.ansible.com/v1beta1 kind: AWX metadata: name: awx-kubernetes spec: service_type: nodeport hostname: vip.example.com extra_settings: - setting: MIDDLEWARE value: "['corsheaders.middleware.CorsMiddleware'] + MIDDLEWARE" - setting: CORS_ORIGIN_ALLOW_ALL value: "True"

Additional information

No response

Operator Logs

No response

Guida contributor