From 1f8d14e8c39e1b0f7ad88eb3d113214a2e220c6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Ricks?= Date: Tue, 27 Feb 2024 11:03:47 +0100 Subject: [PATCH] Fix getting the uuid of the admin user in container startup script There could be more then one user starting with admin in their names like foo_admin or admin_foo. Therefore fix the grep command to only show the user admin. --- .docker/start-gvmd.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.docker/start-gvmd.sh b/.docker/start-gvmd.sh index 6ef724f44..7083b8f81 100644 --- a/.docker/start-gvmd.sh +++ b/.docker/start-gvmd.sh @@ -44,7 +44,7 @@ gvmd --migrate || true gvmd --create-user=$USER --password=$PASSWORD || true # set the feed import owner -uid=$(gvmd --get-users --verbose | grep $USER | awk '{print $2}') +uid=$(gvmd --get-users --verbose | grep "^$USER " | awk '{print $2}') gvmd --modify-setting 78eceaec-3385-11ea-b237-28d24461215b --value "$uid" echo "starting gvmd"