czechlight-cfg-fs: replace NACM restore service with a migration
Currently we reinitialize ietf-netconf-acm module after each boot by
importing a set of rules. This means that after each boot the NACM
configuration was overwritten with "our" configuration.
This is not what we want. Admin of our box might want to adjust the
NACM rules as he see fit.
Therefore it makes sense to create a migration that sets the default
NACM rules by us and other people can modify them.
When migrating to this OS version (config version 4) we overwrite any
existing NACM rules for the last time as a part of the migration.
Starting from this version users are free to adjust the NACM rules
as they see fit. These rules *will not* be reset at boot time anymore.
We scanned the git and gerrit history for the reason why NACM rules
were not moved to one of the first migrations but we found nothing on
that. So this is probably just one of the skeletons in the cupboard that
is being removed with this commit.
Change-Id: I084d6eb81fc340c09abc2edf2995ff40b219e807
diff --git a/package/velia/velia-firewall.service b/package/velia/velia-firewall.service
index e5dd1d6..3fc8839 100644
--- a/package/velia/velia-firewall.service
+++ b/package/velia/velia-firewall.service
@@ -1,9 +1,9 @@
[Unit]
Description=Firewall management via sysrepo
-After=syslog.target network.target cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service
+After=syslog.target network.target cfg-restore-sysrepo.service czechlight-migrate.service
Before=rauc-mark-good.service
PartOf=netopeer2.service
-Requires=cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service
+Requires=cfg-restore-sysrepo.service czechlight-migrate.service
ConditionKernelCommandLine=czechlight
[Service]
diff --git a/package/velia/velia-hardware-g1.service b/package/velia/velia-hardware-g1.service
index cb0cd30..0efa671 100644
--- a/package/velia/velia-hardware-g1.service
+++ b/package/velia/velia-hardware-g1.service
@@ -1,9 +1,9 @@
[Unit]
Description=Tracking hardware metrics
-After=syslog.target network.target cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service
+After=syslog.target network.target cfg-restore-sysrepo.service czechlight-migrate.service
Before=rauc-mark-good.service
PartOf=netopeer2.service
-Requires=cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service
+Requires=cfg-restore-sysrepo.service czechlight-migrate.service
ConditionKernelCommandLine=|czechlight=sdn-inline
ConditionKernelCommandLine=|czechlight=sdn-roadm-add-drop
ConditionKernelCommandLine=|czechlight=sdn-roadm-coherent-a-d
diff --git a/package/velia/velia-hardware-g2.service b/package/velia/velia-hardware-g2.service
index 8a58eab..1186979 100644
--- a/package/velia/velia-hardware-g2.service
+++ b/package/velia/velia-hardware-g2.service
@@ -1,9 +1,9 @@
[Unit]
Description=Tracking hardware metrics
-After=syslog.target network.target cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service
+After=syslog.target network.target cfg-restore-sysrepo.service czechlight-migrate.service
Before=rauc-mark-good.service
PartOf=netopeer2.service
-Requires=cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service
+Requires=cfg-restore-sysrepo.service czechlight-migrate.service
ConditionKernelCommandLine=|czechlight=sdn-inline-g2
ConditionKernelCommandLine=|czechlight=sdn-roadm-add-drop-g2
ConditionKernelCommandLine=|czechlight=sdn-roadm-coherent-a-d-g2
diff --git a/package/velia/velia-health.service b/package/velia/velia-health.service
index d755099..f2cd48e 100644
--- a/package/velia/velia-health.service
+++ b/package/velia/velia-health.service
@@ -1,7 +1,7 @@
[Unit]
Description=Health tracking of the whole system
-Requires=multi-user.target cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service sysrepo-ietf-alarms.service
-After=multi-user.target cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service sysrepo-ietf-alarms.service
+Requires=multi-user.target cfg-restore-sysrepo.service czechlight-migrate.service sysrepo-ietf-alarms.service
+After=multi-user.target cfg-restore-sysrepo.service czechlight-migrate.service sysrepo-ietf-alarms.service
ConditionKernelCommandLine=czechlight
[Service]
diff --git a/package/velia/velia-system.service b/package/velia/velia-system.service
index 113be5c..2fd6a7e 100644
--- a/package/velia/velia-system.service
+++ b/package/velia/velia-system.service
@@ -1,9 +1,9 @@
[Unit]
Description=System management via sysrepo
-After=syslog.target network.target cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service
+After=syslog.target network.target cfg-restore-sysrepo.service czechlight-migrate.service
Before=rauc-mark-good.service
PartOf=netopeer2.service
-Requires=cfg-restore-sysrepo.service czechlight-migrate.service nacm-restore.service
+Requires=cfg-restore-sysrepo.service czechlight-migrate.service
ConditionKernelCommandLine=czechlight
[Service]