Page MenuHomeVyOS Platform

Establish common file name pattern for XML conf mode commands
Closed, ResolvedPublicFEATURE REQUEST

Description

When looking at the XML definitions in vyos-1x:interface-definitions/ we see a lot of mixed patterns.

-rw-r--r--  1 vyos vyos  1738 Aug  6 19:32 bcast-relay.xml.in
-rw-r--r--  1 vyos vyos 17522 Aug  6 19:32 container.xml.in
-rw-r--r--  1 vyos vyos  2633 Aug  6 19:32 cron.xml.in
-rw-r--r--  1 vyos vyos  5166 Aug  6 19:32 dhcp-relay.xml.in
-rw-r--r--  1 vyos vyos 22988 Aug  6 19:32 dhcp-server.xml.in

-rw-r--r--  1 vyos vyos  2654 Aug  6 19:32 system-lcd.xml.in
-rw-r--r--  1 vyos vyos  1040 Aug  6 19:32 system-login-banner.xml.in

Same applies for the conf_mode scripts in vyos-1x:src/conf_mode/

-rwxr-xr-x  1 vyos vyos 31050 Aug 11 20:53 interfaces-openvpn.py
-rwxr-xr-x  1 vyos vyos  4498 Aug  6 19:32 interfaces-pppoe.py
-rwxr-xr-x  1 vyos vyos  3447 Aug  6 19:32 interfaces-pseudo-ethernet.py
-rwxr-xr-x  1 vyos vyos  4920 Aug  6 19:32 interfaces-sstpc.py
-rwxr-xr-x  1 vyos vyos  9665 Aug 11 20:53 interfaces-tunnel.py
-rwxr-xr-x  1 vyos vyos  3673 Aug  6 19:32 interfaces-virtual-ethernet.py
-rwxr-xr-x  1 vyos vyos  1797 Aug  6 19:32 interfaces-vti.py

-rwxr-xr-x  1 vyos vyos  2771 Aug 11 20:53 service_config_sync.py
-rwxr-xr-x  1 vyos vyos  4191 Aug 11 20:53 service_console-server.py
-rwxr-xr-x  1 vyos vyos  2544 Aug  6 19:32 service_event_handler.py
-rwxr-xr-x  1 vyos vyos  3461 Aug 11 20:53 service_ids_fastnetmon.py
-rwxr-xr-x  1 vyos vyos  7038 Aug  6 19:32 service_ipoe-server.py
-rwxr-xr-x  1 vyos vyos  4150 Aug  6 19:32 service_mdns-repeater.py
-rwxr-xr-x  1 vyos vyos  8008 Aug 11 20:53 service_monitoring_telegraf.py
-rwxr-xr-x  1 vyos vyos  2748 Aug 11 22:26 service_monitoring_zabbix-agent.py

The idea is to make this more clear to the users which file is used for which part of the system. The guideline is as follows and applies to both XML and conf_mode python scripts.
The filename should contain the path in the config hirarchy and cofig levels should be separated by _. If a service name has a hyphen (-) in it, keep it.

  • src/conf_mode/dhcp_server.py -> src/conf_mode/service_dhcp-server.py
  • src/conf_mode/interfaces-pseudo-ethernet.py -> src/conf_mode/interfaces_pseudo-ethernet.py
  • interface-definitions/dhcp-server.xml.in -> interface-definitions/service_dhcp-server.xml.in
  • interface-definitions/interfaces-pseudo-ethernet.xml.in -> interface-definitions/interfaces_pseudo-ethernet.xml.in

op-mode is not covered by this change!

Details

Difficulty level
Normal (likely a few hours)
Version
1.4-rolling
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Perfectly compatible
Issue type
Internal change (not visible to end users)

Event Timeline

c-po changed the task status from Open to Confirmed.Aug 14 2023, 5:54 AM
c-po claimed this task.
c-po triaged this task as Wishlist priority.
c-po created this task.
c-po updated the task description. (Show Details)
c-po changed Difficulty level from Unknown (require assessment) to Normal (likely a few hours).
c-po changed Is it a breaking change? from Unspecified (possibly destroys the router) to Perfectly compatible.
c-po changed Issue type from Unspecified (please specify) to Internal change (not visible to end users).
c-po changed Version from - to 1.4-rolling.Aug 14 2023, 6:00 AM
c-po added a project: VyOS 1.5 Circinus.
c-po moved this task from Need Triage to Finished on the VyOS 1.4 Sagitta board.
c-po moved this task from Need Triage to Finished on the VyOS 1.5 Circinus board.