Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Nest
Gentoo
Portage
Commits
726b525c
Commit
726b525c
authored
Jan 27, 2021
by
James T. Lee
Browse files
CI: Do build stage in separate pipeline from sync
parent
5b33c060
Pipeline
#453
passed with stage
in 1 minute and 8 seconds
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
.gitlab-ci.yml
.gitlab-ci.yml
+6
-3
No files found.
.gitlab-ci.yml
View file @
726b525c
...
@@ -5,6 +5,8 @@ stages:
...
@@ -5,6 +5,8 @@ stages:
'
Sync
Portage'
:
'
Sync
Portage'
:
stage
:
'
sync'
stage
:
'
sync'
rules
:
-
if
:
'
$BUILD_IMAGE
!=
"1"'
script
:
script
:
# Config
# Config
-
'
git
config
--global
user.name
"Nest
CI"'
-
'
git
config
--global
user.name
"Nest
CI"'
...
@@ -34,13 +36,14 @@ stages:
...
@@ -34,13 +36,14 @@ stages:
-
'
git
add
.'
-
'
git
add
.'
-
'
git
commit
-m
"$(date
-I)
snapshot"'
-
'
git
commit
-m
"$(date
-I)
snapshot"'
-
'
git
remote
set-url
origin
git@gitlab.james.tl:nest/gentoo/portage.git'
-
'
git
remote
set-url
origin
git@gitlab.james.tl:nest/gentoo/portage.git'
-
'
git
push
-o
ci.
skip
origin
"HEAD:${CI_COMMIT_BRANCH}"'
-
'
git
push
-o
ci.
variable="BUILD_IMAGE=1"
origin
"HEAD:${CI_COMMIT_BRANCH}"'
'
Build
Image'
:
'
Build
Image'
:
stage
:
'
build'
image
:
'
${CI_REGISTRY}/nest/tools/buildah:${CI_HOST_CPU}'
image
:
'
${CI_REGISTRY}/nest/tools/buildah:${CI_HOST_CPU}'
stage
:
'
build'
rules
:
-
if
:
'
$BUILD_IMAGE
==
"1"'
script
:
script
:
-
'
git
pull'
-
'
buildah
login
-u
"$CI_REGISTRY_USER"
-p
"$CI_REGISTRY_PASSWORD"
"$CI_REGISTRY"'
-
'
buildah
login
-u
"$CI_REGISTRY_USER"
-p
"$CI_REGISTRY_PASSWORD"
"$CI_REGISTRY"'
-
'
buildah
bud
--pull
-t
"$CI_REGISTRY_IMAGE"
-f
.Containerfile
.'
-
'
buildah
bud
--pull
-t
"$CI_REGISTRY_IMAGE"
-f
.Containerfile
.'
-
'
buildah
push
"$CI_REGISTRY_IMAGE"'
-
'
buildah
push
"$CI_REGISTRY_IMAGE"'
James T. Lee
@james
mentioned in issue
#2
·
Jan 27, 2021
mentioned in issue
#2
mentioned in issue #2
Toggle commit list
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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