Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
D
dev-el6
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
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
Code review analytics
Issue analytics
Insights
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
Software Control System
Containers
dev-el6
Commits
c7c437d0
Commit
c7c437d0
authored
1 year ago
by
MADELA Patrick
Browse files
Options
Downloads
Patches
Plain Diff
Update .gitlab-ci.yml file
parent
5498c220
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#2974
failed
1 year ago
Stage: build
Stage: test
Stage: release
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
.gitlab-ci.yml
+22
-7
22 additions, 7 deletions
.gitlab-ci.yml
with
22 additions
and
7 deletions
.gitlab-ci.yml
+
22
−
7
View file @
c7c437d0
...
...
@@ -3,18 +3,33 @@ services:
-
docker:dind
variables
:
LATEST_VER
:
"
registry.gitlab.com/synchrotron-soleil/control-system/containers/dev-el6:latest"
NAME
:
dev-el6
CONTAINER_TEST_IMAGE
:
${CI_REGISTRY_IMAGE}/${NAME}:$CI_COMMIT_REF_SLUG
CONTAINER_RELEASE_IMAGE
:
${CI_REGISTRY_IMAGE}/${NAME}:latest
stages
:
-
build
-
test
-
release
build-job
:
stage
:
build
# only:
# - master
before_script
:
-
echo "$REGISTRY_PASSWORD" | docker login
registry.gitlab.com -u "$
REGISTRY_USER
"
--password-stdin
-
echo "$
{CI_
REGISTRY_PASSWORD
}
" | docker login
-u ${CI_
REGISTRY_USER
}
--password-stdin
${CI_REGISTRY}
script
:
-
docker info
-
docker build -t $LATEST_VER .
-
docker push $LATEST_VER
-
docker build --pull -t ${CONTAINER_TEST_IMAGE} .
-
docker push ${CONTAINER_TEST_IMAGE}
test
:
stage
:
test
script
:
-
docker run --rm ${CONTAINER_TEST_IMAGE} cat /etc/centos-release | grep "CentOS release 6"
-
docker run --rm ${CONTAINER_TEST_IMAGE} gcc --version | grep "gcc (GCC) 4\.4"
-
docker run --rm ${CONTAINER_TEST_IMAGE} uname -m | grep "x86_64"
release
:
stage
:
release
script
:
-
docker pull ${CONTAINER_TEST_IMAGE}
-
docker tag ${CONTAINER_TEST_IMAGE} ${CONTAINER_RELEASE_IMAGE}
-
docker push ${CONTAINER_RELEASE_IMAGE}
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