tests: zabbix: Set 'PATH' before running the scripts.

This is a followup to 8b9cad01e9.

* gnu/tests/monitoring.scm (run-zabbix-server-test)[test]: Set 'PATH' in
MARIONETTE.
This commit is contained in:
Ludovic Courtès 2020-03-09 23:02:12 +01:00
parent 8a49e63b2d
commit 7e5f016cdb
No known key found for this signature in database
GPG Key ID: 090B11993D9AEBB5
1 changed files with 7 additions and 0 deletions

View File

@ -194,6 +194,13 @@ cat ~a | sudo -u zabbix psql zabbix;
(start-service 'postgres))
marionette))
;; Add /run/setuid-programs to $PATH so that the scripts passed to
;; 'system' can find 'sudo'.
(marionette-eval
'(setenv "PATH"
"/run/setuid-programs:/run/current-system/profile/bin")
marionette)
(test-eq "postgres create zabbix user"
0
(marionette-eval '(begin (system #$%psql-user-create-zabbix))