Remove hardcoded LOGNAME for ansible-playbook

This meant bubblewrap needed to have a zuul user on the host system,
which when gathering facts on localhost would cause an ansible
failure.  Additionally, this no longer is needed because our logging
is now handled by zuul_stream.

Change-Id: I75cd050e26438dbe6d47ff216ffe6e08b9687aca
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
changes/49/485749/1
Paul Belanger 5 years ago
parent ab070c2ac0
commit 8546a9b235
No known key found for this signature in database
GPG Key ID: 611A80832067AF38
  1. 4
      zuul/executor/server.py

@ -1315,7 +1315,6 @@ class AnsibleJob(object):
def runAnsible(self, cmd, timeout, config_file, trusted):
env_copy = os.environ.copy()
env_copy.update(self.ssh_agent.env)
env_copy['LOGNAME'] = 'zuul'
env_copy['ZUUL_JOB_OUTPUT_FILE'] = self.jobdir.job_output_file
env_copy['ZUUL_JOBDIR'] = self.jobdir.root
pythonpath = env_copy.get('PYTHONPATH')
@ -1415,9 +1414,6 @@ class AnsibleJob(object):
def runAnsiblePlaybook(self, playbook, timeout, success=None,
phase=None, index=None):
env_copy = os.environ.copy()
env_copy['LOGNAME'] = 'zuul'
if self.executor_server.verbose:
verbose = '-vvv'
else:

Loading…
Cancel
Save