Skip to content

Commit 298d2ad

Browse files
authored
[boot] Refactor: All services which start Docker containers start before ntp-config service (#2335)
1 parent d608a83 commit 298d2ad

File tree

11 files changed

+11
-1
lines changed

11 files changed

+11
-1
lines changed

files/build_templates/bgp.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Description=BGP container
33
Requires=updategraph.service
44
After=updategraph.service
5+
Before=ntp-config.service
56

67
[Service]
78
User={{ sonicadmin_user }}

files/build_templates/dhcp_relay.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Description=DHCP relay container
33
Requires=updategraph.service swss.service teamd.service
44
After=updategraph.service swss.service teamd.service
5+
Before=ntp-config.service
56

67
[Service]
78
User={{ sonicadmin_user }}

files/build_templates/lldp.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Description=LLDP container
33
Requires=updategraph.service
44
After=updategraph.service
5+
Before=ntp-config.service
56

67
[Service]
78
User={{ sonicadmin_user }}

files/build_templates/pmon.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Description=Platform monitor container
33
Requires=updategraph.service
44
After=updategraph.service
5+
Before=ntp-config.service
56

67
[Service]
78
User={{ sonicadmin_user }}

files/build_templates/radv.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Description=Router advertiser container
33
Requires=updategraph.service swss.service
44
After=updategraph.service swss.service
5+
Before=ntp-config.service
56

67
[Service]
78
User={{ sonicadmin_user }}

files/build_templates/snmp.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Description=SNMP container
33
Requires=updategraph.service swss.service
44
After=updategraph.service swss.service
5+
Before=ntp-config.service
56

67
[Service]
78
ExecStartPre=/usr/bin/{{docker_container_name}}.sh start

files/build_templates/swss.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ Requires=nps-modules-4.9.0-7-amd64.service
88
{% endif %}
99
After=database.service updategraph.service
1010
After=interfaces-config.service
11+
Before=ntp-config.service
1112

1213
[Service]
1314
User=root

files/build_templates/syncd.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ After=opennsl-modules-4.9.0-7-amd64.service
1313
{% elif sonic_asic_platform == 'nephos' %}
1414
After=nps-modules-4.9.0-7-amd64.service
1515
{% endif %}
16+
Before=ntp-config.service
1617

1718
[Service]
1819
User=root

files/build_templates/teamd.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Description=TEAMD container
33
Requires=updategraph.service
44
After=updategraph.service
5+
Before=ntp-config.service
56

67
[Service]
78
User={{ sonicadmin_user }}

files/build_templates/telemetry.service.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Description=Telemetry container
33
Requires=swss.service
44
After=swss.service
5+
Before=ntp-config.service
56

67
[Service]
78
User={{ sonicadmin_user }}

files/image_config/ntp/ntp-config.service

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[Unit]
22
Description=Update NTP configuration
33
Requires=updategraph.service
4-
After=updategraph.service bgp.service dhcp_relay.service lldp.service pmon.service radv.service snmp.service swss.service syncd.service teamd.service
4+
After=updategraph.service
55

66
[Service]
77
Type=oneshot

0 commit comments

Comments
 (0)