this is my first question here, I am so excited :)
It's maybe a noob question but I don't understand it...
I'am trying to upgrade an Edgerouter firmware (https://www.ui.com/edgemax/edgerouter-pro/) with Gitlab-CI and Ansible. The stages are absolutely identical but the stdout of the same task, with the same ansible.cfg, with the same gitlab-runner, in the same pipeline etc., differs:
STAGE1
CI Deployment Docker Image:
ansible-playbook 2.8.3
python version = 3.7.4
Edgerouter:
USER1@HOSTNAME1:~$ python --version
Python 2.7.13
USER1@HOSTNAME1:~$ show system image
The system currently has the following image(s) installed:
v2.0.8.5247496.191120.1124 (running image) (default boot)
v2.0.8.5247496.191120.1124-1
OUTPUT
...identical verbose output, but:
ok: [HOSTNAME1] => changed=false
invocation:
module_args:
commands:
- show version | grep "Build ID" | cut -d ':' -f 2 | tr -d ' '
interval: 1
match: all
retries: 10
wait_for: null
stdout:
- '5247496'
stdout_lines: <omitted>
Works like a charm! BUT:
STAGE2
CI Deployment Image:
ansible-playbook 2.8.3
python version = 3.7.4
Edgerouter
USER2@HOSTNAME2:~$ python --version
Python 2.7.13
USER2@HOSTNAME2:~$ show system image
The system currently has the following image(s) installed:
v2.0.8.5247496.191120.1124 (running image) (default boot)
v2.0.8.5247496.191120.1124-1
OUTPUT
...identical verbose output, but:
ok: [HOSTNAME2] => changed=false
invocation:
module_args:
commands:
- show version | grep "Build ID" | cut -d ':' -f 2 | tr -d ' '
interval: 1
match: all
retries: 10
wait_for: null
stdout:
- |-
show version | grep "Build ID" | cut -d ':' -f 2 |
tr -d ' '
5247496
stdout_lines: <omitted>
DOES NOT... This is the Ansible task:
- name: get installed firmware build ID to compare with config
edgeos_command:
commands: show version | grep "Build ID" | cut -d ':' -f 2 | tr -d ' '
register: installed_firmware_build_id
tags: router-upgrade
What am I missing here?