Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
eic_container
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
containers
eic_container
Compare revisions
667d361b143c5a85f1cb317411b838b320971830 to ccc0e22813ba0269d0981ecc8d48e027236fc89a
Compare revisions
Changes are shown as if the
source
revision was being merged into the
target
revision.
Learn more about comparing revisions.
Source
containers/eic_container
Select target project
No results found
ccc0e22813ba0269d0981ecc8d48e027236fc89a
Select Git revision
Swap
Target
containers/eic_container
Select target project
containers/eic_container
wdconinc/eic_container
tooba/eic_container
3 results
667d361b143c5a85f1cb317411b838b320971830
Select Git revision
Show changes
Only incoming changes from source
Include changes to target since source was created
Compare
Commits on Source (2)
fix: enable view without activating env
· aeac427e
Wouter Deconinck
authored
1 year ago
aeac427e
feat: use oci build cache on eicweb and ghcr
· ccc0e228
Wouter Deconinck
authored
1 year ago
ccc0e228
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
containers/jug/dev.Dockerfile
+3
-12
3 additions, 12 deletions
containers/jug/dev.Dockerfile
mirrors.yaml.in
+12
-0
12 additions, 0 deletions
mirrors.yaml.in
spack-environment/Makefile
+7
-3
7 additions, 3 deletions
spack-environment/Makefile
with
22 additions
and
15 deletions
containers/jug/dev.Dockerfile
View file @
ccc0e228
...
...
@@ -70,14 +70,6 @@ spack compiler find --scope site
spack config blame compilers
EOF
## Setup local buildcache mirrors
RUN
--mount
=
type
=
cache,target
=
/var/cache/spack
<<
EOF
set -e
spack mirror add local /var/cache/spack/mirror/${SPACK_VERSION}
spack buildcache update-index local
spack mirror list
EOF
## Setup eics3 buildcache mirrors
## - this always adds the read-only mirror to the container
## - the write-enabled mirror is provided later as a secret mount
...
...
@@ -144,13 +136,13 @@ RUN --mount=type=cache,target=/ccache,id=${TARGETPLATFORM} \
<<
EOF
set -e
export CCACHE_DIR=/ccache
spack buildcache update-index local
find /var/cache/spack/blobs/sha256/ -atime +7 -delete
spack buildcache update-index eics3rw
spack env activate --dir ${SPACK_ENV}
spack add juggler@git.${JUGGLER_VERSION}
spack add eicrecon@git.${EICRECON_VERSION}
spack concretize --fresh --force --quiet
make --jobs ${jobs} --keep-going --directory /opt/spack-environment SPACK_ENV=${SPACK_ENV} BUILDCACHE_MIRROR
="local eics3rw
"
make --jobs ${jobs} --keep-going --directory /opt/spack-environment SPACK_ENV=${SPACK_ENV} BUILDCACHE_MIRROR
_ONLY_PACKAGE="eics3rw" BUILDCACHE_MIRROR_DEPENDENCIES="eicweb ghcr
"
ccache --show-stats
ccache --zero-stats
EOF
...
...
@@ -158,9 +150,8 @@ EOF
## Create view at /usr/local
RUN
--mount
=
type
=
cache,target
=
/var/cache/spack
<<
EOF
set -e
spack env activate --dir ${SPACK_ENV}
rm -r /usr/local
spack env view enable /usr/local
spack
-e ${SPACK_ENV}
env view enable /usr/local
EOF
## Optional, nuke the buildcache after install, before (re)caching
...
...
This diff is collapsed.
Click to expand it.
mirrors.yaml.in
View file @
ccc0e228
mirrors:
eicweb:
url: oci://${CI_REGISTRY}/${CI_PROJECT_PATH}/spack-${SPACK_VERSION}
push:
access_pair:
- ${CI_REGISTRY_USER}
- ${CI_REGISTRY_PASSWORD}
ghcr:
url: oci://ghcr.io/eic/spack-${SPACK_VERSION}
push:
access_pair:
- ${GITHUB_REGISTRY_USER}
- ${GITHUB_REGISTRY_TOKEN}
eics3rw:
fetch:
url: s3://eictest/EPIC/spack/${SPACK_VERSION}
...
...
This diff is collapsed.
Click to expand it.
spack-environment/Makefile
View file @
ccc0e228
...
...
@@ -7,7 +7,9 @@ export SPACK_COLOR = always
SPACK_ENV
?=
dev
BUILDCACHE_MIRROR
:=
BUILDCACHE_MIRROR_ONLY_PACKAGE
:=
BUILDCACHE_MIRROR_DEPENDENCIES
:=
BUILDCACHE_OCI_BASE_IMAGE
:=
ghcr.io/eic/debian:stable-slim
.PHONY
:
all clean
...
...
@@ -18,11 +20,13 @@ include $(SPACK_ENV)/spack.mk
endif
$(SPACK_ENV)/push
:
$(addprefix $(SPACK_ENV)/push/
,
$($(SPACK_ENV)/SPACK_PACKAGE_IDS))
$(
foreach buildcache,
$(
BUILDCACHE_MIRROR
)
,
$(
SPACK
)
buildcache update-index
$(
buildcache
)
;)
$(
foreach buildcache,
$(
BUILDCACHE_MIRROR_ONLY_PACKAGE
)
,
$(
SPACK
)
buildcache update-index
$(
buildcache
)
;)
$(
foreach buildcache,
$(
BUILDCACHE_MIRROR_DEPENDENCIES
)
,
$(
SPACK
)
buildcache update-index
$(
buildcache
)
;)
$(SPACK_ENV)/push/%
:
$(SPACK_ENV)/install/%
@
mkdir
-p
$(
dir
$@
)
$(
foreach buildcache,
$(
BUILDCACHE_MIRROR
)
,
$(
SPACK
)
buildcache push
--only
=
package
--unsigned
$(
buildcache
)
/
$(
HASH
)
;)
# push
$(
SPEC
)
$(
foreach buildcache,
$(
BUILDCACHE_MIRROR_ONLY_PACKAGE
)
,
$(
SPACK
)
buildcache push
--only
=
package
--unsigned
$(
buildcache
)
/
$(
HASH
)
;)
# push
$(
SPEC
)
$(
foreach buildcache,
$(
BUILDCACHE_MIRROR_DEPENDENCIES
)
,
$(
SPACK
)
buildcache push
--unsigned
--base-image
$(
BUILDCACHE_OCI_BASE_IMAGE
)
$(
buildcache
)
/
$(
HASH
)
|
grep
-v
"Using cached archive"
;)
# push
$(
SPEC
)
@
touch
$@
$(SPACK_ENV)/spack.lock
:
$(SPACK_ENV)/spack.yaml Makefile
...
...
This diff is collapsed.
Click to expand it.