Skip to content

Commit

Permalink
Set up docker for arcade
Browse files Browse the repository at this point in the history
  • Loading branch information
dsplaisted committed Nov 8, 2018
1 parent 56344d0 commit cc776c8
Show file tree
Hide file tree
Showing 19 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ done

dockerbuild()
{
BUILD_COMMAND=/opt/code/run-build.sh $DIR/scripts/dockerrun.sh --non-interactive "$@"
BUILD_COMMAND=/opt/code/run-build.sh $DIR/eng/dockerrun.sh --non-interactive "$@"
}

# Check if we need to build in docker
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
22 changes: 11 additions & 11 deletions old/scripts/dockerrun.sh → eng/dockerrun.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ while [[ $# > 0 ]]; do
echo ""
echo "Options:"
echo " <Dockerfile> The path to the Dockerfile to use to create the build container"
echo " <ImageName> The name of an existing Dockerfile folder under scripts/docker to use as the Dockerfile"
echo " <ImageName> The name of an existing Dockerfile folder under eng/docker to use as the Dockerfile"
echo " <Command> The command to run once inside the container (/opt/code is mapped to the repo root; defaults to nothing, which runs the default shell)"
exit 0
;;
Expand All @@ -54,44 +54,44 @@ if [ -z "$DOCKERFILE" ]; then
if [ -z "$DOCKER_IMAGENAME" ]; then
if [ "$(uname)" == "Darwin" ]; then
echo "Defaulting to 'ubuntu' image for Darwin"
export DOCKERFILE=scripts/docker/ubuntu
export DOCKERFILE=eng/docker/ubuntu
elif [ "$(cat /etc/*-release | grep -cim1 ubuntu)" -eq 1 ]; then
echo "Detected current OS as Ubuntu, determining ubuntu version to use..."
if [ "$(cat /etc/*-release | grep -cim1 16.04)" -eq 1 ]; then
echo "using 'ubuntu.16.04' image"
export DOCKERFILE=scripts/docker/ubuntu.16.04
export DOCKERFILE=eng/docker/ubuntu.16.04
else
echo "using 'ubuntu' image"
export DOCKERFILE=scripts/docker/ubuntu
export DOCKERFILE=eng/docker/ubuntu
fi
elif [ "$(cat /etc/*-release | grep -cim1 centos)" -eq 1 ]; then
echo "Detected current OS as CentOS, using 'centos' image"
export DOCKERFILE=scripts/docker/centos
export DOCKERFILE=eng/docker/centos
elif [ "$(cat /etc/*-release | grep -cim1 rhel)" -eq 1 ]; then
echo "Detected current OS as rhel, using 'rhel' image"
export DOCKERFILE=scripts/docker/rhel
export DOCKERFILE=eng/docker/rhel
elif [ "$(cat /etc/*-release | grep -cim1 debian)" -eq 1 ]; then
echo "Detected current OS as Debian, using 'debian' image"
export DOCKERFILE=scripts/docker/debian
export DOCKERFILE=eng/docker/debian
elif [ "$(cat /etc/*-release | grep -cim1 fedora)" -eq 1 ]; then
echo "Detected current OS as Fedora, determining fedora version to use..."
if [ "$(cat /etc/*-release | grep -cim1 23)" -eq 1 ]; then
echo "using 'fedora.23' image"
export DOCKERFILE=scripts/docker/fedora.23
export DOCKERFILE=eng/docker/fedora.23
fi
elif [ "$(cat /etc/*-release | grep -cim1 opensuse)" -eq 1 ]; then
echo "Detected current OS as openSUSE, determining openSUSE version to use..."
if [ "$(cat /etc/*-release | grep -cim1 13.2)" -eq 1 ]; then
echo "using 'openSUSE.13.2' image"
export DOCKERFILE=scripts/docker/opensuse.13.2
export DOCKERFILE=eng/docker/opensuse.13.2
fi
else
echo "Unknown Linux Distro. Using 'ubuntu' image"
export DOCKERFILE=scripts/docker/ubuntu
export DOCKERFILE=eng/docker/ubuntu
fi
else
echo "Using requested image: $DOCKER_IMAGENAME"
export DOCKERFILE="scripts/docker/$DOCKER_IMAGENAME"
export DOCKERFILE="eng/docker/$DOCKER_IMAGENAME"
fi
fi

Expand Down
2 changes: 1 addition & 1 deletion run-build.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ REPOROOT="$DIR"

ARCHITECTURE="x64"

source "$REPOROOT/scripts/common/_prettyprint.sh"
source "$REPOROOT/eng/_prettyprint.sh"

LINUX_PORTABLE_INSTALL_ARGS=
CUSTOM_BUILD_ARGS=
Expand Down

0 comments on commit cc776c8

Please sign in to comment.