Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
A
apertis-image-recipes
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Denis Pynkin
apertis-image-recipes
Commits
e556244e
Commit
e556244e
authored
7 years ago
by
Denis Pynkin
Browse files
Options
Downloads
Patches
Plain Diff
WIP: add fake stage
parent
816a4b52
Branches
T4489
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Jenkinsfile
+44
-3
44 additions, 3 deletions
Jenkinsfile
with
44 additions
and
3 deletions
Jenkinsfile
+
44
−
3
View file @
e556244e
...
...
@@ -21,6 +21,39 @@ def uploadDirectory(source, target, upload = true) {
}
}
def
fakeBuild
(
architecture
,
type
,
board
,
debosarguments
=
""
,
sysroot
=
false
,
ostree
=
false
,
production
=
false
)
{
return
{
node
(
"docker-slave"
)
{
checkout
scm
docker
.
withRegistry
(
'https://docker-registry.apertis.org'
)
{
buildenv
=
docker
.
image
(
"docker-registry.apertis.org/apertis/apertis-${release}-image-builder"
)
/* Pull explicitely to ensure we have the latest */
buildenv
.
pull
()
buildenv
.
inside
(
"--device=/dev/kvm"
)
{
stage
(
"setup ${architecture} ${type}"
)
{
env
.
PIPELINE_VERSION
=
VersionNumber
(
versionNumberString:
'${BUILD_DATE_FORMATTED,"yyyyMMdd"}.${BUILDS_TODAY_Z}'
)
sh
(
"env ; mkdir -p ${PIPELINE_VERSION}/${architecture}/${type}"
)
}
try
{
stage
(
"${architecture} ${type} fake stage"
)
{
sh
(
script:
"""\
cd ${PIPELINE_VERSION}/${architecture}/${type}; \
while true; do echo 'Please do not stop me -- need for main Apertis build'; sleep 120; done"""
)
}
}
finally
{
stage
(
"Cleanup ${architecture} ${type}"
)
{
deleteDir
()
}
}
}
}
}
}
}
def
buildImage
(
architecture
,
type
,
board
,
debosarguments
=
""
,
sysroot
=
false
,
ostree
=
false
,
production
=
false
)
{
return
{
node
(
"docker-slave"
)
{
...
...
@@ -174,14 +207,22 @@ def images = [:]
// Types for all boards, common debos arguments, sysroots and ospacks
def
types
=
[
[
"minimal"
,
""
,
false
,
true
],
[
"
target
"
,
""
,
false
,
true
]
[
"
fake
"
,
""
,
false
,
true
]
]
images
+=
types
.
collectEntries
{
[
"Amd64 ${it[0]}"
:
fakeBuild
(
"amd64"
,
it
[
0
],
"uefi"
,
it
[
1
],
it
[
2
],
it
[
3
],
production
)
]
}
/*
def types = [ [ "minimal", "", false, true],
[ "target", "", false, true],
[ "development", "--scratchsize 10G", false, false]
]
*/
images += types.collectEntries { [ "Amd64 ${it[0]}": buildImage("amd64",
it[0],
...
...
@@ -206,5 +247,5 @@ images += types.collectEntries { [ "Armhf ${it[0]}": buildImage("armhf",
it[2],
it[3],
production ) ] }
*/
parallel
images
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