Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
olcf
container-builder
Commits
41a381af
Commit
41a381af
authored
Jan 27, 2018
by
AdamSimpson
Browse files
simplify docker backend
parent
3d37c99e
Pipeline
#11517
failed with stages
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Scripts/docker-builder-backend.sh
View file @
41a381af
...
...
@@ -15,21 +15,9 @@ case ${i} in
esac
done
# Provide read only access to the private gitlab docker repository if using the container-recipes docker registry
grep
'code.ornl.gov:4567'
./container.def
GREP_RC
=
$?
if
[[
$GREP_RC
-eq
0
]]
;
then
echo
"Using container recipes docker registry login credentials"
docker
${
DEBUG_FLAG
}
login code.ornl.gov:4567
-u
$(
cat
/home/builder/gitlab-username
)
-p
$(
cat
/home/builder/gitlab-readonly-token
)
fi
# provide read only access to the private olcf dockerhub repository
grep
'FROM olcf/'
./container.def
GREP_RC
=
$?
if
[[
$GREP_RC
-eq
0
]]
;
then
echo
"Using OLCF Dockerhub registry login credentials"
docker
${
DEBUG_FLAG
}
login code.ornl.gov:4567
-u
$(
cat
/home/builder/dockerhub-readonly-username
)
-p
$(
cat
/home/builder/dockerhub-readonly-password
)
fi
# Provide read-only access to gitlab registry and dockerhub
docker
${
DEBUG_FLAG
}
login code.ornl.gov:4567
-u
$(
cat
/home/builder/gitlab-username
)
-p
$(
cat
/home/builder/gitlab-readonly-token
)
docker
${
DEBUG_FLAG
}
login code.ornl.gov:4567
-u
$(
cat
/home/builder/dockerhub-readonly-username
)
-p
$(
cat
/home/builder/dockerhub-readonly-password
)
# Spin up local registry
docker
${
DEBUG_FLAG
}
run
-d
-p
5000:5000
--restart
=
always
--name
registry registry:2
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment