
Build the docker image for the new package index REST API on each merge/push to develop and master.
18 lines
434 B
Bash
Executable File
18 lines
434 B
Bash
Executable File
#!/usr/bin/env bash
|
|
#
|
|
# Copyright 2013-2019 Lawrence Livermore National Security, LLC and other
|
|
# Spack Project Developers. See the top-level COPYRIGHT file for details.
|
|
#
|
|
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
|
|
|
|
script="$( basename "$0" )"
|
|
cd "$( dirname "$0" )"
|
|
|
|
export IMAGE="spack/packages.spack.io:latest"
|
|
|
|
if [ "$script" '=' 'push-image.sh' ] ; then
|
|
docker push "${IMAGE}"
|
|
else
|
|
docker build -f -t "${IMAGE}" .
|
|
fi
|