Skip to content

Commit

Permalink
Run mux simulator script per testbed (#15255)
Browse files Browse the repository at this point in the history
What is the motivation for this PR?
As mux_simulator script differs between branches, let's copy mux_simulator per testbed.

How did you do it?
Use the port number as suffix.

How did you verify/test it?
Run on dualtor testbeds that share the same host server, ensure mux_simulators run with each owne script file.

Signed-off-by: Longxiang Lyu <[email protected]>
  • Loading branch information
lolyu authored and mssonicbld committed Oct 31, 2024
1 parent beb25ac commit 442a8a3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ansible/roles/vm_set/tasks/control_mux_simulator.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
- name: Copy the mux simulator to test server
copy:
src: mux_simulator.py
dest: "{{ abs_root_path }}"
dest: "{{ abs_root_path }}/mux_simulator_{{ mux_simulator_port }}.py"
mode: 0755

- name: Generate mux-simulator systemd service file
Expand Down
2 changes: 1 addition & 1 deletion ansible/roles/vm_set/templates/mux-simulator.service.j2
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ Description=mux simulator
After=network.target

[Service]
ExecStart=/usr/bin/env {{python_command}} {{ abs_root_path }}/mux_simulator.py {{ mux_simulator_port }} {{ vm_set_name }} -v
ExecStart=/usr/bin/env {{python_command}} {{ abs_root_path }}/mux_simulator_{{ mux_simulator_port }}.py {{ mux_simulator_port }} {{ vm_set_name }} -v

0 comments on commit 442a8a3

Please sign in to comment.