gopkg.in/openshift/source-to-image.v1@v1.2.0/hack/build-test-images.sh (about)

     1  #!/bin/bash
     2  
     3  # This script builds all images locally (requires Docker)
     4  
     5  set -o errexit
     6  set -o nounset
     7  set -o pipefail
     8  
     9  readonly S2I_ROOT=$(dirname "${BASH_SOURCE}")/..
    10  
    11  s2i::build_test_image() {
    12    local image_name="$1"
    13    local tag="sti_test/${image_name}"
    14    local src="test/integration/images/${image_name}"
    15    cp -R test/integration/scripts "${src}"
    16    docker build -t "${tag}" "${src}"
    17    rm -rf "${src}/scripts"
    18  }
    19  
    20  (
    21    # Go to the top of the tree.
    22    cd "${S2I_ROOT}"
    23  
    24    s2i::build_test_image sti-fake
    25    s2i::build_test_image sti-fake-assemble-root
    26    s2i::build_test_image sti-fake-assemble-user
    27    s2i::build_test_image sti-fake-env
    28    s2i::build_test_image sti-fake-user
    29    s2i::build_test_image sti-fake-scripts
    30    s2i::build_test_image sti-fake-scripts-no-save-artifacts
    31    s2i::build_test_image sti-fake-no-tar
    32    s2i::build_test_image sti-fake-onbuild
    33    s2i::build_test_image sti-fake-numericuser
    34    s2i::build_test_image sti-fake-onbuild-rootuser
    35    s2i::build_test_image sti-fake-onbuild-numericuser
    36  )