sonic-buildimage/dockers/docker-sonic-mgmt-framework
Tamer Ahmed afc952535e [mgmt-framework] Call sonic-cfggen Once (#4937)
Optimizing number of calls made to sonic-cfggen during service
start up as it adds to total system boot up time.

***-Test 1***
there is an average saving of 1 to 1.5 sec between old script and new script
```
root@str-s6000-acs-14:/# time /usr/bin/rest-server-old.sh
Generating temporary TLS server certificate ...
2020/07/09 19:03:33 wrote cert.pem
2020/07/09 19:03:33 wrote key.pem
REST_SERVER_ARGS = -ui /rest_ui -logtostderr -cert /tmp/cert.pem -key /tmp/key.pem
/usr/sbin/rest_server -ui /rest_ui -logtostderr -cert /tmp/cert.pem -key /tmp/key.pem

real	0m8.790s
user	0m7.993s
sys	0m0.584s
root@str-s6000-acs-14:/# time /usr/bin/rest-server-new.sh
Generating temporary TLS server certificate ...
2020/07/09 19:03:45 wrote cert.pem
2020/07/09 19:03:45 wrote key.pem
REST_SERVER_ARGS = -ui /rest_ui -logtostderr -cert /tmp/cert.pem -key /tmp/key.pem
/usr/sbin/rest_server -ui /rest_ui -logtostderr -cert /tmp/cert.pem -key /tmp/key.pem

real	0m6.940s
user	0m5.670s
sys	0m0.386s
```
***-Test 2***
Built an image with this change and rest server is running with params as described in test 1 above
```
admin@str-s6000-acs-14:~$ ps -ef | grep rest_server
root      3301  2866  2 02:09 pts/0    00:00:10 /usr/sbin/rest_server -ui /rest_ui -logtostderr -cert /tmp/cert.pem -key /tmp/key.pem

```

signed-off-by: Tamer Ahmed <tamer.ahmed@microsoft.com>
2020-12-22 09:51:54 -08:00
..
base_image_files SONiC Management Framework Release 1.0 (#3488) 2020-01-08 15:51:02 -08:00
Dockerfile.j2 [mgmt-framework] Call sonic-cfggen Once (#4937) 2020-12-22 09:51:54 -08:00
mgmt_vars.j2 [mgmt-framework] Call sonic-cfggen Once (#4937) 2020-12-22 09:51:54 -08:00
rest-server.sh [mgmt-framework] Call sonic-cfggen Once (#4937) 2020-12-22 09:51:54 -08:00
start.sh [docker-mgmt-framework]: use service dependency in supervisord to start services 2020-08-15 22:25:38 -07:00
supervisord.conf [dockers][supervisor] Increase event buffer size for dependent-startup (#5247) 2020-09-28 16:12:53 +00:00