-
-
Save Mikulas/f1de18f91176e739b5f56c0a0d7e5c9a to your computer and use it in GitHub Desktop.
DooD docker out of docker volume mount in kubernetes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MOUNT_IN_JENKINS="/var/jenkins_home/workspace" | |
CONTAINER_ID="$(docker ps --filter "volume=$MOUNT_IN_JENKINS" --format '{{.ID}}')" | |
HOST_DIR="$(docker inspect "$CONTAINER_ID" | jq --raw-output '.[0].Mounts[] | select(.Destination=="'"$MOUNT_IN_JENKINS"'").Source')" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment