Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
easybuild-repository-public-release
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
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
DEEP-SEA
easybuild-repository-public-release
Commits
52a055b9
Commit
52a055b9
authored
3 years ago
by
Damian Alvarez
Browse files
Options
Downloads
Patches
Plain Diff
To make sure that some conditions are just applied when not installing
in production
parent
eb975a9d
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
Custom_Hooks/eb_hooks.py
+5
-5
5 additions, 5 deletions
Custom_Hooks/eb_hooks.py
with
5 additions
and
5 deletions
Custom_Hooks/eb_hooks.py
+
5
−
5
View file @
52a055b9
...
...
@@ -265,7 +265,7 @@ def inject_site_contact_and_user_labels(ec):
# not sure of a fool-proof way to do this, let's just try a heuristic
site_contacts
=
None
# Non-user installation
if
'
/p/software
'
in
install_path
().
lower
():
if
install_path
().
lower
()
.
startswith
(
'
/p/software
'
)
:
if
'
swmanage
'
in
os
.
getenv
(
'
USER
'
):
site_contacts
=
common_site_contact
else
:
...
...
@@ -342,7 +342,7 @@ def inject_modaltsoftname(ec):
def
inject_ucx_features
(
ec
):
# UCX require to load UCX-settings
ec_dict
=
ec
.
asdict
()
if
ec
.
name
in
'
UCX
'
and
'
/p/software
'
in
install_path
().
lower
():
if
ec
.
name
in
'
UCX
'
and
install_path
().
lower
()
.
startswith
(
'
/p/software
'
)
:
key
=
"
modluafooter
"
value
=
'''
if not ( isloaded(
"
UCX-settings
"
) ) then
...
...
@@ -362,7 +362,7 @@ end
def
inject_mpi_features
(
ec
):
ec_dict
=
ec
.
asdict
()
# MPIs are a family (in the Lmod sense) and require to load mpi-settings
if
ec
.
name
in
SUPPORTED_MPIS
and
'
/p/software
'
in
install_path
().
lower
():
if
ec
.
name
in
SUPPORTED_MPIS
and
install_path
().
lower
()
.
startswith
(
'
/p/software
'
)
:
key
=
"
modluafooter
"
value
=
'''
if not ( isloaded(
"
mpi-settings
"
) ) then
...
...
@@ -418,7 +418,7 @@ def pre_ready_hook(self, *args, **kwargs):
override_toolchain_check
=
os
.
getenv
(
"
JSC_OVERRIDE_TOOLCHAIN_CHECK
"
)
if
not
override_toolchain_check
:
toolchain_name
=
toolchain
[
"
name
"
]
if
not
toolchain_name
in
SUPPORTED_TOOLCHAIN_FAMILIES
and
os
.
getenv
(
'
USER
'
)
not
in
'
swmanag
e
'
:
if
not
toolchain_name
in
SUPPORTED_TOOLCHAIN_FAMILIES
and
not
install_path
().
lower
().
startswith
(
'
/p/softwar
e
'
)
:
stage
=
os
.
getenv
(
"
STAGE
"
,
default
=
None
)
if
stage
:
# Clean things up if it is a Devel stage
...
...
@@ -446,7 +446,7 @@ def pre_ready_hook(self, *args, **kwargs):
# experts should know that. This applies just to user installations
override_gcccore_check
=
os
.
getenv
(
"
JSC_OVERRIDE_GCCCORE_CHECK
"
)
if
not
override_gcccore_check
:
if
is_gcccore
and
not
"
stages
"
in
install_path
().
lower
():
if
is_gcccore
and
not
install_path
().
lower
()
.
startswith
(
'
/p/software
'
)
:
print_warning
(
"
\n
You are attempting to install GCCcore (%s) into a non-system
"
"
location (%s), this won
'
t work as expected without additional effort
"
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment