13 lines
396 B
Bash
Executable File
13 lines
396 B
Bash
Executable File
#!/bin/sh
|
|
|
|
set -xe
|
|
|
|
sudo chown airflow:airflow airflow
|
|
airflow db init
|
|
|
|
# Allow non-authenticated access to UI for Airflow 2.*
|
|
sed -i.bak -E 's/^(# )?(AUTH_ROLE_PUBLIC) = .*$/\2 = "Admin"/' /home/airflow/airflow/webserver_config.py
|
|
|
|
# Allow unauthenticated API access for terraform
|
|
sed -i.bak -E 's/^(auth_backends) = .*$/\1 = airflow.api.auth.backend.default/' /home/airflow/airflow/airflow.cfg
|