[pcluster pipeline] Use local buildcache instead of upstream spack
Spack currently does not relocate compiler references from upstream spack installations. When using a buildcache we don't need an upstream spack.
This commit is contained in:
parent
91a54029f9
commit
27aebae256
@ -792,16 +792,14 @@ deprecated-ci-build:
|
|||||||
|
|
||||||
.aws-pcluster-generate:
|
.aws-pcluster-generate:
|
||||||
before_script:
|
before_script:
|
||||||
# Setup postinstall Spack as upstream installation
|
# Use gcc from local container buildcache
|
||||||
- - . "./share/spack/setup-env.sh"
|
- - . "./share/spack/setup-env.sh"
|
||||||
- . /etc/profile.d/modules.sh
|
- . /etc/profile.d/modules.sh
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/packages.yaml ]]; then cp /bootstrap/spack/etc/spack/packages.yaml ./etc/spack/; fi
|
- spack mirror add local-cache /bootstrap/local-cache
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/config.yaml ]]; then cp /bootstrap/spack/etc/spack/config.yaml ./etc/spack/; fi
|
- spack gpg trust /bootstrap/public-key
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/modules.xyaml ]]; then cp /bootstrap/spack/etc/spack/modules.yaml ./etc/spack/; fi
|
- spack install --cache-only $(spack buildcache list gcc | tail -n1)
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/mirrors.yaml ]]; then cp /bootstrap/spack/etc/spack/mirrors.yaml ./etc/spack/; fi
|
|
||||||
- if [[ -d /bootstrap/spack/opt/spack ]]; then spack config add "upstreams:postinstall:install_tree:/bootstrap/spack/opt/spack"; fi
|
|
||||||
- cd "${CI_PROJECT_DIR}" && curl -sOL https://raw.githubusercontent.com/spack/spack-configs/main/AWS/parallelcluster/postinstall.sh
|
- cd "${CI_PROJECT_DIR}" && curl -sOL https://raw.githubusercontent.com/spack/spack-configs/main/AWS/parallelcluster/postinstall.sh
|
||||||
- sed -i -e '/nohup/s/&$//' -e 's/nohup//' -e "s/spack arch -t/echo ${SPACK_TARGET_ARCH}/g" postinstall.sh
|
- sed -i -e "s/spack arch -t/echo ${SPACK_TARGET_ARCH}/g" postinstall.sh
|
||||||
- /bin/bash postinstall.sh -fg
|
- /bin/bash postinstall.sh -fg
|
||||||
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
||||||
after_script:
|
after_script:
|
||||||
|
@ -41,12 +41,10 @@ spack:
|
|||||||
- . /etc/profile.d/modules.sh
|
- . /etc/profile.d/modules.sh
|
||||||
- spack --version
|
- spack --version
|
||||||
- spack arch
|
- spack arch
|
||||||
# Setup postinstall Spack as upstream installation
|
# Use gcc from local container buildcache
|
||||||
- - if [[ -f /bootstrap/spack/etc/spack/packages.yaml ]]; then cp /bootstrap/spack/etc/spack/packages.yaml ./etc/spack/; fi
|
- - spack mirror add local-cache /bootstrap/local-cache
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/config.yaml ]]; then cp /bootstrap/spack/etc/spack/config.yaml ./etc/spack/; fi
|
- spack gpg trust /bootstrap/public-key
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/modules.yaml ]]; then cp /bootstrap/spack/etc/spack/modules.yaml ./etc/spack/; fi
|
- spack install --cache-only $(spack buildcache list gcc | tail -n1)
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/mirrors.yaml ]]; then cp /bootstrap/spack/etc/spack/mirrors.yaml ./etc/spack/; fi
|
|
||||||
- if [[ -d /bootstrap/spack/opt/spack ]]; then spack config add "upstreams:postinstall:install_tree:/bootstrap/spack/opt/spack"; fi
|
|
||||||
- - /bin/bash "${SPACK_ARTIFACTS_ROOT}/postinstall.sh" -fg
|
- - /bin/bash "${SPACK_ARTIFACTS_ROOT}/postinstall.sh" -fg
|
||||||
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
||||||
- signing-job:
|
- signing-job:
|
||||||
|
@ -43,12 +43,10 @@ spack:
|
|||||||
- . /etc/profile.d/modules.sh
|
- . /etc/profile.d/modules.sh
|
||||||
- spack --version
|
- spack --version
|
||||||
- spack arch
|
- spack arch
|
||||||
# Setup postinstall Spack as upstream installation
|
# Use gcc from local container buildcache
|
||||||
- - if [[ -f /bootstrap/spack/etc/spack/packages.yaml ]]; then cp /bootstrap/spack/etc/spack/packages.yaml ./etc/spack/; fi
|
- - spack mirror add local-cache /bootstrap/local-cache
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/config.yaml ]]; then cp /bootstrap/spack/etc/spack/config.yaml ./etc/spack/; fi
|
- spack gpg trust /bootstrap/public-key
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/modules.yaml ]]; then cp /bootstrap/spack/etc/spack/modules.yaml ./etc/spack/; fi
|
- spack install --cache-only $(spack buildcache list gcc | tail -n1)
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/mirrors.yaml ]]; then cp /bootstrap/spack/etc/spack/mirrors.yaml ./etc/spack/; fi
|
|
||||||
- if [[ -d /bootstrap/spack/opt/spack ]]; then spack config add "upstreams:postinstall:install_tree:/bootstrap/spack/opt/spack"; fi
|
|
||||||
- - /bin/bash "${SPACK_ARTIFACTS_ROOT}/postinstall.sh" -fg
|
- - /bin/bash "${SPACK_ARTIFACTS_ROOT}/postinstall.sh" -fg
|
||||||
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
||||||
- signing-job:
|
- signing-job:
|
||||||
|
@ -43,12 +43,10 @@ spack:
|
|||||||
- . /etc/profile.d/modules.sh
|
- . /etc/profile.d/modules.sh
|
||||||
- spack --version
|
- spack --version
|
||||||
- spack arch
|
- spack arch
|
||||||
# Setup postinstall Spack as upstream installation
|
# Use gcc from local container buildcache
|
||||||
- - if [[ -f /bootstrap/spack/etc/spack/packages.yaml ]]; then cp /bootstrap/spack/etc/spack/packages.yaml ./etc/spack/; fi
|
- - spack mirror add local-cache /bootstrap/local-cache
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/config.yaml ]]; then cp /bootstrap/spack/etc/spack/config.yaml ./etc/spack/; fi
|
- spack gpg trust /bootstrap/public-key
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/modules.yaml ]]; then cp /bootstrap/spack/etc/spack/modules.yaml ./etc/spack/; fi
|
- spack install --cache-only $(spack buildcache list gcc | tail -n1)
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/mirrors.yaml ]]; then cp /bootstrap/spack/etc/spack/mirrors.yaml ./etc/spack/; fi
|
|
||||||
- if [[ -d /bootstrap/spack/opt/spack ]]; then spack config add "upstreams:postinstall:install_tree:/bootstrap/spack/opt/spack"; fi
|
|
||||||
- - /bin/bash "${SPACK_ARTIFACTS_ROOT}/postinstall.sh" -fg
|
- - /bin/bash "${SPACK_ARTIFACTS_ROOT}/postinstall.sh" -fg
|
||||||
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
||||||
- signing-job:
|
- signing-job:
|
||||||
|
@ -41,12 +41,10 @@ spack:
|
|||||||
- . /etc/profile.d/modules.sh
|
- . /etc/profile.d/modules.sh
|
||||||
- spack --version
|
- spack --version
|
||||||
- spack arch
|
- spack arch
|
||||||
# Setup postinstall Spack as upstream installation
|
# Use gcc from local container buildcache
|
||||||
- - if [[ -f /bootstrap/spack/etc/spack/packages.yaml ]]; then cp /bootstrap/spack/etc/spack/packages.yaml ./etc/spack/; fi
|
- - spack mirror add local-cache /bootstrap/local-cache
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/config.yaml ]]; then cp /bootstrap/spack/etc/spack/config.yaml ./etc/spack/; fi
|
- spack gpg trust /bootstrap/public-key
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/modules.yaml ]]; then cp /bootstrap/spack/etc/spack/modules.yaml ./etc/spack/; fi
|
- spack install --cache-only $(spack buildcache list gcc | tail -n1)
|
||||||
- if [[ -f /bootstrap/spack/etc/spack/mirrors.yaml ]]; then cp /bootstrap/spack/etc/spack/mirrors.yaml ./etc/spack/; fi
|
|
||||||
- if [[ -d /bootstrap/spack/opt/spack ]]; then spack config add "upstreams:postinstall:install_tree:/bootstrap/spack/opt/spack"; fi
|
|
||||||
- - /bin/bash "${SPACK_ARTIFACTS_ROOT}/postinstall.sh" -fg
|
- - /bin/bash "${SPACK_ARTIFACTS_ROOT}/postinstall.sh" -fg
|
||||||
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
- spack config --scope site add "packages:all:target:\"target=${SPACK_TARGET_ARCH}\""
|
||||||
- signing-job:
|
- signing-job:
|
||||||
|
Loading…
Reference in New Issue
Block a user