Skip to content

Commit

Permalink
manager: allow arguments in the osism update scripts (#1242)
Browse files Browse the repository at this point in the history
Closes osism/python-osism#700

Signed-off-by: Christian Berendt <[email protected]>
  • Loading branch information
berendt committed Dec 19, 2023
1 parent 7f578f3 commit d16419f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
fixes:
- |
Allow use of arguments in the osism update commands.
12 changes: 8 additions & 4 deletions roles/manager/templates/wrapper/osism.j2
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,19 @@ fi

# The update from the manager is done with osism-update-manager script as
# it cannot be done within a container as it is recreated during the update.
if [[ "$@" == "update manager" ]]; then
exec /usr/local/bin/osism-update-manager
if [[ "$@" = *"update manager"* ]]; then
shift
shift
exec /usr/local/bin/osism-update-manager "$@"
fi

# The update from the docker service on the manager is done with
# osism-update-docker script as it cannot be done within a container as it
# may be recreated during the update.
if [[ "$@" == "update docker" ]]; then
exec /usr/local/bin/osism-update-docker
if [[ "$@" = *"update docker"* ]]; then
shift
shift
exec /usr/local/bin/osism-update-docker "$@"
fi

docker exec $PARAMETERS osismclient osism "$@"

0 comments on commit d16419f

Please sign in to comment.