Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F3929007
D3275.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
903 B
Referenced Files
None
Subscribers
None
D3275.id.diff
View Options
diff --git a/roles/paas-docker/containers/files/airflow/airflow.sh.jinja b/roles/paas-docker/containers/files/airflow/airflow.sh.jinja
--- a/roles/paas-docker/containers/files/airflow/airflow.sh.jinja
+++ b/roles/paas-docker/containers/files/airflow/airflow.sh.jinja
@@ -41,6 +41,15 @@
COMMAND=version
fi
+if [ "$COMMAND" = "shell" ]; then
+ PROGRAM=bash
+ COMMAND=
+ COMMAND_ARGS=
+else
+ PROGRAM=airflow
+ COMMAND_ARGS=$@
+fi
+
dsn="$(credential {{ credentials.postgresql }} username):$(credential {{ credentials.postgresql }})@{{ services.postgresql }}"
docker run -it --rm \
--network {{ network }} \
@@ -48,4 +57,4 @@
-e CONNECTION_CHECK_MAX_COUNT=0 \
-e AIRFLOW__DATABASE__SQL_ALCHEMY_CONN="postgresql+psycopg2://$dsn/airflow" \
$EXTRA_ARGS \
- nasqueron/airflow bash -c "airflow $COMMAND $@"
+ nasqueron/airflow $PROGRAM $COMMAND $COMMAND_ARGS
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Dec 23, 07:09 (10 h, 50 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2311722
Default Alt Text
D3275.id.diff (903 B)
Attached To
Mode
D3275: Allow to enter a shell for Airflow maintenance operations
Attached
Detach File
Event Timeline
Log In to Comment