From: David Galloway Date: Wed, 29 Sep 2021 15:37:02 +0000 (-0400) Subject: ansible: Set file.encoding=UTF-8 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F1915%2Fhead;p=ceph-build.git ansible: Set file.encoding=UTF-8 Requested by Ernesto via e-mail. See https://stackoverflow.com/questions/27960996/jenkins-console-output-characters Signed-off-by: David Galloway --- diff --git a/ansible/examples/slave.yml b/ansible/examples/slave.yml index 666142745..4f255bb01 100644 --- a/ansible/examples/slave.yml +++ b/ansible/examples/slave.yml @@ -759,6 +759,8 @@ ansible_python_interpreter: /usr/bin/python when: (ansible_os_family == "RedHat" and ansible_distribution_major_version|int <= 7) or (ansible_os_family == "Debian" and ansible_distribution_major_version|int <= 16) + tags: + - register - set_fact: pip_version: pip3 @@ -766,6 +768,8 @@ when: (ansible_os_family == "RedHat" and ansible_distribution_major_version|int >= 8) or (ansible_os_family == "Debian" and ansible_distribution_major_version|int >= 18) or ansible_os_family == "Suse" + tags: + - register - name: Install six, latest one pip: @@ -773,6 +777,8 @@ state: latest executable: "{{ pip_version }}" when: ansible_os_family != "Suse" + tags: + - register - name: Install python-jenkins # https://review.openstack.org/460363 @@ -780,6 +786,8 @@ name: python-jenkins version: 0.4.15 executable: "{{ pip_version }}" + tags: + - register ## LIBVIRT SERVICE TASKS - name: start libvirt services diff --git a/ansible/templates/systemd/jenkins.service.j2 b/ansible/templates/systemd/jenkins.service.j2 index badcfc12d..a71de7ca2 100644 --- a/ansible/templates/systemd/jenkins.service.j2 +++ b/ansible/templates/systemd/jenkins.service.j2 @@ -11,6 +11,7 @@ WantedBy=multi-user.target Type=simple User={{ jenkins_user }} ExecStart=/usr/bin/java \ + -Dfile.encoding=UTF8 \ -jar /home/{{ jenkins_user }}/slave.jar \ -jnlpUrl {{ api_uri }}/computer/{{ ansible_default_ipv4.address }}+{{ nodename }}/slave-agent.jnlp \ -jnlpCredentials @/etc/systemd/system/jenkins.secret