You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

38 lines
1.2 KiB

  1. #!/bin/sh
  2. # Warning, problems can occur if the device restarts in the middle of this uci-default script
  3. if [ -x /bin/sysrepoctl ]; then
  4. match=$(sysrepoctl -l | grep "ietf-netconf-notifications ")
  5. if [ ! "$match" ]; then
  6. sysrepoctl --install --yang=/etc/sysrepo/yang/ietf-netconf-notifications.yang -p 666
  7. fi
  8. match=$(sysrepoctl -l | grep "ietf-netconf-with-default ")
  9. if [ ! "$match" ]; then
  10. sysrepoctl --install --yang=/etc/sysrepo/yang/ietf-netconf-with-defaults.yang -p 666
  11. fi
  12. match=$(sysrepoctl -l | grep "ietf-origin ")
  13. if [ ! "$match" ]; then
  14. sysrepoctl --install --yang=/etc/sysrepo/yang/ietf-origin.yang -p 644
  15. fi
  16. match=$(sysrepoctl -l | grep "sysrepo ")
  17. if [ ! "$match" ]; then
  18. sysrepoctl --install --yang=/etc/sysrepo/yang/sysrepo.yang -p 600
  19. fi
  20. match=$(sysrepoctl -l | grep "ietf-netconf ")
  21. if [ ! "$match" ]; then
  22. sysrepoctl --install --yang=/etc/sysrepo/yang/ietf-netconf.yang -p 600
  23. fi
  24. sysrepoctl -m ietf-netconf -e writable-running
  25. sysrepoctl -m ietf-netconf -e candidate
  26. sysrepoctl -m ietf-netconf -e rollback-on-error
  27. sysrepoctl -m ietf-netconf -e validate
  28. sysrepoctl -m ietf-netconf -e startup
  29. sysrepoctl -m ietf-netconf -e xpath
  30. fi
  31. exit 0