vitess.io/vitess@v0.16.2/docker/mini/install_mini_dependencies.sh (about)

     1  #!/bin/bash
     2  
     3  # This is a script that gets run as part of the Dockerfile build
     4  # to install dependencies for the vitess/mini image.
     5  #
     6  # Usage: install_mini_dependencies.sh
     7  
     8  set -euo pipefail
     9  
    10  # Install etcd
    11  ETCD_VER=v3.4.9
    12  DOWNLOAD_URL=https://storage.googleapis.com/etcd
    13  
    14  curl -k -L ${DOWNLOAD_URL}/${ETCD_VER}/etcd-${ETCD_VER}-linux-amd64.tar.gz -o /tmp/etcd-${ETCD_VER}-linux-amd64.tar.gz
    15  mkdir -p /var/opt/etcd
    16  sudo tar xzvf /tmp/etcd-${ETCD_VER}-linux-amd64.tar.gz -C /var/opt/etcd --strip-components=1
    17  rm -f /tmp/etcd-${ETCD_VER}-linux-amd64.tar.gz
    18  
    19  mkdir -p /var/run/etcd && chown -R vitess:vitess /var/run/etcd
    20  
    21  # Install orchestrator
    22  curl -k -L https://github.com/openark/orchestrator/releases/download/v3.2.2/orchestrator_3.2.2_amd64.deb -o /tmp/orchestrator.deb
    23  dpkg -i /tmp/orchestrator.deb
    24  rm -f /tmp/orchestrator.deb
    25  cp /usr/local/orchestrator/resources/bin/orchestrator-client /usr/bin
    26  
    27  # Clean up files we won't need in the final image.
    28  rm -rf /var/lib/apt/lists/*