diff options
Diffstat (limited to 'etc/jwstdp-latest/tasks')
-rwxr-xr-x | etc/jwstdp-latest/tasks/001-packages.sh | 38 | ||||
-rwxr-xr-x | etc/jwstdp-latest/tasks/002-python-packages.sh | 40 | ||||
-rwxr-xr-x | etc/jwstdp-latest/tasks/999-clean.sh | 18 |
3 files changed, 0 insertions, 96 deletions
diff --git a/etc/jwstdp-latest/tasks/001-packages.sh b/etc/jwstdp-latest/tasks/001-packages.sh deleted file mode 100755 index e64fe06..0000000 --- a/etc/jwstdp-latest/tasks/001-packages.sh +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/bash -set -e -set -x - -sysconfdir="${TOOLCHAIN_BUILD}/etc/${PIPELINE}" -reqdir=${sysconfdir}/pkgs -blddir=builds - - -function pre() -{ - if [[ ! -d ${reqdir} ]]; then - # Nothing there, but maybe that's on purpose. - exit 0 - fi - mkdir -p "${blddir}" - pushd ${blddir} &>/dev/null -} - -function build() -{ - pre - # Iterate over binary package build scripts - for req in ${reqdir}/* - do - chmod +x "${req}" - "${req}" - done - post -} - -function post() -{ - popd &>/dev/null - [[ -d ${blddir} ]] && rm -rf "${blddir}" -} - -build diff --git a/etc/jwstdp-latest/tasks/002-python-packages.sh b/etc/jwstdp-latest/tasks/002-python-packages.sh deleted file mode 100755 index 33714aa..0000000 --- a/etc/jwstdp-latest/tasks/002-python-packages.sh +++ /dev/null @@ -1,40 +0,0 @@ -#!/bin/bash -set -e -set -x - -# Uses GLOBAL environment variable: PYTHON_VERSION defined by `docker build` argument -prefix="${TOOLCHAIN}" -sysconfdir="${TOOLCHAIN_BUILD}/etc/${PIPELINE}" -reqdir=${sysconfdir}/pip - -export PATH="${prefix}/bin:${PATH}" -export CFLAGS="-I${prefix}/include" -export LDFLAGS="-L${prefix}/lib -Wl,-rpath=${prefix}/lib" - -function pre() -{ - if [[ ! -d ${reqdir} ]]; then - # Nothing there, but maybe that's on purpose. - exit 0 - fi -} - -function build() -{ - pre - # Iterate over pip requirement files - for req in ${reqdir}/* - do - pip install --upgrade --progress-bar=off -r "${req}" - done - post -} - -function post() -{ - rm -rf ~/.cache/pip - [[ -d src ]] && rm -rf src || true - [[ -f gmon.out ]] && rm -rf gmon.out || true -} - -build diff --git a/etc/jwstdp-latest/tasks/999-clean.sh b/etc/jwstdp-latest/tasks/999-clean.sh deleted file mode 100755 index 7487b9c..0000000 --- a/etc/jwstdp-latest/tasks/999-clean.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/bash -x -if [[ ! -f /.dockerenv ]]; then - echo "This script cannot be executed outside of a docker container." - exit 1 -fi - -rm -rf "${HOME}/.astropy" -rm -rf "${HOME}/.cache" -rm -rf "${HOME}"/* - -sudo yum clean all -sudo rm -rf /tmp/* -sudo rm -rf /var/cache/yum - -for logfile in /var/log/* -do - sudo truncate --size=0 "${logfile}" -done |