XD-DENG commented on a change in pull request #4050: [AIRFLOW-3178] Don't bake 
ENV and _cmd into tmp config for non-sudo
URL: https://github.com/apache/incubator-airflow/pull/4050#discussion_r227456884
 
 

 ##########
 File path: airflow/task/task_runner/base_task_runner.py
 ##########
 @@ -58,13 +58,18 @@ def __init__(self, local_task_job):
             except conf.AirflowConfigException:
                 self.run_as_user = None
 
-        # Always provide a copy of the configuration file settings
-        cfg_path = tmp_configuration_copy()
-
         # Add sudo commands to change user if we need to. Needed to handle 
SubDagOperator
         # case using a SequentialExecutor.
         self.log.debug("Planning to run as the %s user", self.run_as_user)
         if self.run_as_user and (self.run_as_user != getpass.getuser()):
+            # We want to include any environment variables now, as we won't
+            # wany to have to specify them in the sudo call - they would show
+            # up in `ps` that way! And ruun commands now, as the other user
 
 Review comment:
   Typo "ruun" -> "run"?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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

Reply via email to