diff --git a/docker/build-image.sh b/docker/build-image.sh index a4bcbf7a..ed48c4f3 100755 --- a/docker/build-image.sh +++ b/docker/build-image.sh @@ -41,7 +41,7 @@ while [[ $# -gt 0 ]]; do ;; -d|--develop) USERNAME=usdotfhwastoldev - COMPONENT_VERSION_STRING=noetic-develop + COMPONENT_VERSION_STRING=develop shift ;; esac @@ -55,7 +55,7 @@ echo "Building docker image for $IMAGE version: $COMPONENT_VERSION_STRING" echo "Final image name: $USERNAME/$IMAGE:$COMPONENT_VERSION_STRING" cd .. -if [[ $COMPONENT_VERSION_STRING = "noetic-develop" ]]; then +if [[ $COMPONENT_VERSION_STRING = "develop" ]]; then sed "s|usdotfhwastoldev/|$USERNAME/|g; s|usdotfhwastolcandidate/|$USERNAME/|g; s|usdotfhwastol/|$USERNAME/|g; s|:[0-9]*\.[0-9]*\.[0-9]*|:$COMPONENT_VERSION_STRING|g; s|checkout.bash|checkout.bash -d|g" \ Dockerfile | docker build -f - --no-cache -t $USERNAME/$IMAGE:$COMPONENT_VERSION_STRING \ --build-arg VERSION="$COMPONENT_VERSION_STRING" \ diff --git a/docker/checkout.bash b/docker/checkout.bash index ccddfd77..1bfe05b8 100755 --- a/docker/checkout.bash +++ b/docker/checkout.bash @@ -24,7 +24,7 @@ while [[ $# -gt 0 ]]; do arg="$1" case $arg in -d|--develop) - BRANCH=noetic/develop + BRANCH=develop shift ;; -r|--root) @@ -35,7 +35,7 @@ while [[ $# -gt 0 ]]; do esac done -if [[ "$BRANCH" = "noetic/develop" ]]; then +if [[ "$BRANCH" = "develop" ]]; then git clone https://github.com/usdot-fhwa-stol/carma-msgs.git ~/src/carma-msgs --branch $BRANCH --depth 1 git clone https://github.com/usdot-fhwa-stol/carma-utils.git ~/src/carma-utils --branch $BRANCH --depth 1 else diff --git a/hooks/pre_build b/hooks/pre_build index 5fa97f45..1b199017 100644 --- a/hooks/pre_build +++ b/hooks/pre_build @@ -1,8 +1,8 @@ #!/bin/bash -if [[ "$SOURCE_BRANCH" = "noetic/develop" ]]; then +if [[ "$SOURCE_BRANCH" = "develop" ]]; then # add -d flag to checkout.bash and update image dependencies - sed -i "s|checkout.bash|checkout.bash -d|g; s|usdotfhwastol/|usdotfhwastoldev/|g; s|:[0-9]*\.[0-9]*\.[0-9]*|:noetic-develop|g s|:CARMA[a-zA-Z]*_[0-9]*\.[0-9]*\.[0-9]*|:noetic-develop|g; s|:carma-[a-zA-Z]*-[0-9]*\.[0-9]*\.[0-9]*|:noetic-develop|g" \ + sed -i "s|checkout.bash|checkout.bash -d|g; s|usdotfhwastol/|usdotfhwastoldev/|g; s|:[0-9]*\.[0-9]*\.[0-9]*|:develop|g s|:CARMA[a-zA-Z]*_[0-9]*\.[0-9]*\.[0-9]*|:develop|g; s|:carma-[a-zA-Z]*-[0-9]*\.[0-9]*\.[0-9]*|:develop|g" \ Dockerfile elif [[ "$SOURCE_BRANCH" =~ ^release/.*$ ]]; then # swap checkout branch in checkout.bash to release branch