ashb commented on a change in pull request #6660: [AIRFLOW-6065] Add
Stackdriver Task Handler
URL: https://github.com/apache/airflow/pull/6660#discussion_r355965513
##########
File path: docs/howto/write-logs.rst
##########
@@ -36,6 +36,38 @@ can not be found or accessed, local logs will be displayed.
Note that logs
are only sent to remote storage once a task is complete (including failure);
In other words, remote logs for
running tasks are unavailable (but local logs are available).
+.. _write-logs-advanced:
+
+Advanced configuration
+''''''''''''''''''''''
+
+Not all configuration options are available from the ``airflow.cfg`` file.
Some configuration options require
+that the logging config class be overwritten. This can be done by
``logging_config_class`` option
+in ``airflow.cfg`` file. This option should specify the import path indicating
to a configuration compatible with
+:class:`logging.config.dictConfig`. If your file is not importable, then you
should set a :any:``PYTHONPATH`` environment.
+
+Follow the steps below to enable custom logging config class:
+
+#. Start by setting environment variable to known directory e.g. ``~/airflow/``
+
+ .. code-block:: ini
+
+ export PYTHON_PATH=~/airflow/
+
+#. Create a directory to store the config file e.g. ``~/airflow/config``
+#. Create empty files called ``~/airflow/config/log_config.py`` and
``~/airflow/config/__init__.py``.
+#. Copy the contents of ``airflow/config_templates/airflow_local_settings.py``
into the ``log_config.py`` file created in ``Step 3``.
+#. Rename ``DEFAULT_LOGGING_CONFIG`` variable into ``LOGGING_CONFIG``.
+#. Update ``$AIRFLOW_HOME/airflow.cfg`` to contain:
+
+ .. code-block:: ini
+
+ remote_logging = True
Review comment:
```suggestion
[core]
remote_logging = True
```
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services