-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(arm) make sure we setup our arm infrastructure (#260)
* fix(arm) make sure we setup our arm infrastructure * fix(arm) move some arm infra installation logic around
- Loading branch information
Showing
3 changed files
with
36 additions
and
22 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,41 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
set -x | ||
|
||
if [ "$RESTY_IMAGE_TAG" != "xenial" ]; then | ||
exit 0 | ||
fi | ||
|
||
docker version | ||
RESULT=$? | ||
if [ "$RESULT" != "0" ]; then | ||
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - | ||
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) test" | ||
sudo apt-get update | ||
sudo apt-get -y -o Dpkg::Options::="--force-confnew" install containerd.io docker-ce | ||
fi | ||
|
||
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - | ||
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) test" | ||
sudo apt-get update | ||
sudo apt-get -y -o Dpkg::Options::="--force-confnew" install containerd.io docker-ce | ||
echo '{"experimental":true}' | sudo tee /etc/docker/daemon.json | ||
curl -fsSLo buildx https://github.com/docker/buildx/releases/download/v0.2.2/buildx-v0.2.2.linux-amd64 | ||
mkdir -p ~/.docker/cli-plugins/ | ||
chmod +x buildx | ||
mv buildx ~/.docker/cli-plugins/docker-buildx | ||
sudo service docker restart | ||
|
||
docker buildx version | ||
RESULT=$? | ||
if [ "$RESULT" != "0" ]; then | ||
curl -fsSLo buildx https://github.com/docker/buildx/releases/download/v0.2.2/buildx-v0.2.2.linux-amd64 | ||
mkdir -p ~/.docker/cli-plugins/ | ||
chmod +x buildx | ||
mv buildx ~/.docker/cli-plugins/docker-buildx | ||
sudo service docker restart | ||
fi | ||
|
||
if ! [ -x "$(command -v docker-machine)" ]; then | ||
curl -L https://github.com/docker/machine/releases/download/v0.16.0/docker-machine-$(uname -s)-$(uname -m) >docker-machine | ||
sudo install docker-machine /usr/local/bin/docker-machine | ||
curl -L https://github.com/docker/machine/releases/download/v0.16.0/docker-machine-$(uname -s)-$(uname -m) >docker-machine | ||
sudo install docker-machine /usr/local/bin/docker-machine | ||
fi | ||
|
||
echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin || true | ||
echo "$REDHAT_PASSWORD" | docker login -u "$REDHAT_USERNAME" registry.access.redhat.com --password-stdin || true | ||
docker-machine version | ||
docker version | ||
docker buildx version | ||
|
||
export BUILDX=true |
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
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