Official Helm Chart version
1.12.0 (latest released)
Apache Airflow version
2.8.2
Kubernetes Version
v1.25.16-eks-77b1e4e
Helm Chart configuration
Excerpt of values.yaml (webserver values)
webserver:
serviceAccount:
create: true
name: airflow-service-account
defaultUser:
enabled: false
webserverConfig: |
from airflow.configuration import conf
from airflow.www.fab_security.manager import AUTH_OAUTH
from my_company.custom_security_manager import CustomSecurityManager
# Enable OAuth authentication
AUTH_TYPE = AUTH_OAUTH
KC_IDP_HINT = conf.get('auth', 'idp_hint')
if KC_IDP_HINT:
KC_IDP_HINT = '?kc_idp_hint=' + KC_IDP_HINT
OAUTH_PROVIDERS = [
{
'name': conf.get('auth', 'provider_name'),
'icon': 'fa-key',
'token_key': 'access_token',
'remote_app': {
'client_id': conf.get('auth', 'client_id'),
'client_secret': conf.get('auth', 'client_secret'),
'api_base_url': conf.get('auth', 'issuer'),
'authorize_url': conf.get('auth', 'authz_url') + KC_IDP_HINT,
'access_token_url': conf.get('auth', 'token_url') + KC_IDP_HINT,
'jwks_uri': conf.get('auth', 'jwks_url'),
'client_kwargs': {
'scope': 'openid email profile'
},
}
}
]
# Will allow user self registration, allowing to create Flask users from Authorized User
AUTH_USER_REGISTRATION = True
# The default user self registration role
AUTH_USER_REGISTRATION_ROLE = 'Public'
# If we should replace ALL the user's roles each login, or only on registration
AUTH_ROLES_SYNC_AT_LOGIN = True
AUTH_ROLES_MAPPING = {
"airflow_admin": ["Admin"],
"airflow_op": ["Op"],
"airflow_user": ["User"],
"airflow_viewer": ["Viewer"],
"airflow_public": ["Public"],
}
# Override default Security Manager
SECURITY_MANAGER_CLASS = CustomSecurityManager
resources:
requests:
cpu: 500m
memory: 2Gi
limits:
cpu: 500m
memory: 2Gi
Docker Image customizations
Dockerfile
#-----------------------------------------------------------------------
FROM python:3.11-slim as airflow-provider
COPY airflow-provider /airflow-provider
WORKDIR /airflow-provider
RUN pip install --no-cache-dir build==0.10.0 && \
python -m build
#-----------------------------------------------------------------------
FROM apache/airflow:2.8.2-python3.11
COPY --from=airflow-provider /airflow-provider/dist/airflow-provider-auth-*.tar.gz airflow-provider-auth.tar.gz
COPY --chown=airflow:0 requirements.txt requirements.txt
RUN pip install --no-cache-dir -r requirements.txt && \
pip install --no-cache-dir airflow-provider-auth.tar.gz
requirements.txt
apache-airflow-providers-cncf-kubernetes==8.0.0
apache-airflow-providers-trino[common.sql]==5.6.2
What happened
When installing the chart, I get the following error message:
Helm upgrade failed: error while running post render on files: map[string]interface {}(nil): yaml: unmarshal errors: line 27: mapping key "ports" already defined at line 26
What you think should happen instead
I expect the chart to be installed successfully.
How to reproduce
Install the chart version 1.12.0 with the webserver values provided.
Anything else
When running helm template --debug charts/airflow --output-dir charts/debug we get the following webserver-service.yaml:
################################
## Airflow Webserver Service
#################################
apiVersion: v1
kind: Service
metadata:
name: airflow-webserver
labels:
tier: airflow
component: webserver
release: release-name
chart: "airflow-chart-1.12.0"
heritage: Helm
spec:
type: ClusterIP
selector:
tier: airflow
component: webserver
release: release-name
ports:
ports:
-
name: airflow-ui
port: 8080
Are you willing to submit PR?
Code of Conduct
Official Helm Chart version
1.12.0 (latest released)
Apache Airflow version
2.8.2
Kubernetes Version
v1.25.16-eks-77b1e4e
Helm Chart configuration
Excerpt of values.yaml (webserver values)
Docker Image customizations
Dockerfile
requirements.txt
What happened
When installing the chart, I get the following error message:
Helm upgrade failed: error while running post render on files: map[string]interface {}(nil): yaml: unmarshal errors: line 27: mapping key "ports" already defined at line 26What you think should happen instead
I expect the chart to be installed successfully.
How to reproduce
Install the chart version 1.12.0 with the webserver values provided.
Anything else
When running
helm template --debug charts/airflow --output-dir charts/debugwe get the following webserver-service.yaml:Are you willing to submit PR?
Code of Conduct