You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/01/18 07:32:57 UTC

[GitHub] [airflow] feluelle commented on a change in pull request #13728: Adds automated user creation in production image

feluelle commented on a change in pull request #13728:
URL: https://github.com/apache/airflow/pull/13728#discussion_r559362160



##########
File path: docs/apache-airflow/production-deployment.rst
##########
@@ -749,6 +749,102 @@ additional apt dev and runtime dependencies.
     --build-arg ADDITIONAL_RUNTIME_APT_DEPS="default-jre-headless"
 
 
+Actions executed at image start
+-------------------------------
+
+If you are using the default entrypoint of the production image,
+there are a few actions that are automatically performed when the container starts.
+In some cases, you can pass environment variables to the image to trigger some of that behaviour.
+
+Creating system user
+....................
+
+Airflow image is Open-Shift compatible, which means that you can start it with random user ID and group id 0.
+Airflow will automatically create such a user and make it's home directory point to /home/airflow.
+You can read more about it in `Openshift best practices <https://docs.openshift.com/container-platform/4.1/openshift_images/create-images.html#images-create-guide-openshift_create-images>`_
+in the "Support arbitrary user ids" chapter.
+
+Verify Airflow DB connection
+............................
+
+In case Postgres or MySQL DB is used, the entrypoint will wait until the airflow DB connection becomes
+available. This happens always when you use the default entrypoint.
+
+Upgrading Airflow DB
+....................
+
+If you set ``_AIRFLOW_DB_UPGRADE`` variable to a non-empty value, the entrypoint will perform

Review comment:
       @potiuk Can you tell me why you decided to prefix the airflow variables with an `_`? Are you just not sure if this is the right way to do this? (i.e are they not worth to be that "public" :D)
   
   If you omit the underscore they're still different to airflow (config) env variables. I just would like to know :)




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org