Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
packer
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kristopher Ruzic
packer
Commits
1e309b66
Commit
1e309b66
authored
Sep 22, 2013
by
Mitchell Hashimoto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
scripts: PACKER_NO_BUILD_PARALLEL to build in sequence
parent
6511b189
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
1 deletion
+17
-1
scripts/build.sh
scripts/build.sh
+17
-1
No files found.
scripts/build.sh
View file @
1e309b66
...
...
@@ -26,6 +26,9 @@ if [ "$(go env GOOS)" = "windows" ]; then
EXTENSION
=
".exe"
fi
# Make sure that if we're killed, we kill all our subprocseses
trap
"kill 0"
SIGINT SIGTERM EXIT
# If we're building a race-enabled build, then set that up.
if
[
!
-z
$PACKER_RACE
]
;
then
echo
-e
"
${
OK_COLOR
}
--> Building with race detection enabled
${
NO_COLOR
}
"
...
...
@@ -50,7 +53,16 @@ waitAll() {
fi
}
echo
-e
"
${
OK_COLOR
}
--> NOTE: Compilation of components will be done in parallel.
${
NO_COLOR
}
"
waitSingle
()
{
if
[
!
-z
$PACKER_NO_BUILD_PARALLEL
]
;
then
waitAll
fi
}
if
[
-z
$PACKER_NO_BUILD_PARALLEL
]
;
then
echo
-e
"
${
OK_COLOR
}
--> NOTE: Compilation of components "
\
"will be done in parallel.
${
NO_COLOR
}
"
fi
# Compile the main Packer app
echo
-e
"
${
OK_COLOR
}
--> Compiling Packer
${
NO_COLOR
}
"
...
...
@@ -62,6 +74,8 @@ go build \
-o
bin/packer
${
EXTENSION
}
.
)
&
waitSingle
# Go over each plugin and build it
for
PLUGIN
in
$(
find ./plugin
-mindepth
1
-maxdepth
1
-type
d
)
;
do
PLUGIN_NAME
=
$(
basename
${
PLUGIN
}
)
...
...
@@ -73,6 +87,8 @@ for PLUGIN in $(find ./plugin -mindepth 1 -maxdepth 1 -type d); do
-v
\
-o
bin/packer-
${
PLUGIN_NAME
}${
EXTENSION
}
${
PLUGIN
}
)
&
waitSingle
done
waitAll
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