BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
b667fba8
Commit
b667fba8
authored
May 05, 2017
by
Balasankar C
Committed by
Marin Jankovski
May 05, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a manual job to trigger package build in omnibus
parent
ccb783ea
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
59 additions
and
0 deletions
+59
-0
.gitlab-ci.yml
.gitlab-ci.yml
+23
-0
README.md
doc/development/README.md
+1
-0
build_test_package.md
doc/development/build_test_package.md
+35
-0
No files found.
.gitlab-ci.yml
View file @
b667fba8
...
...
@@ -23,6 +23,7 @@ before_script:
-
source scripts/prepare_build.sh
stages
:
-
build
-
prepare
-
test
-
post-test
...
...
@@ -137,6 +138,28 @@ stages:
<<
:
*only-master-and-ee-or-mysql
<<
:
*except-docs
# Trigger a package build on omnibus-gitlab repository
build-package
:
services
:
[]
variables
:
SETUP_DB
:
"
false"
USE_BUNDLE_INSTALL
:
"
false"
stage
:
build
when
:
manual
script
:
# If no branch in omnibus is specified, trigger pipeline against master
-
if [ -z "$OMNIBUS_BRANCH" ] ; then export OMNIBUS_BRANCH=master ;fi
-
echo "token=${BUILD_TRIGGER_TOKEN}" > version_details
-
echo "ref=${OMNIBUS_BRANCH}" >> version_details
-
echo "variables[ALTERNATIVE_SOURCES]=true" >> version_details
-
echo "variables[GITLAB_VERSION]=${CI_COMMIT_SHA}" >> version_details
# Collect version details of all components
-
for f in *_VERSION; do echo "variables[$f]=$(cat $f)" >> version_details; done
# Trigger the API and pass values collected above as parameters to it
-
cat version_details | tr '\n' '&' | curl -X POST https://gitlab.com/api/v4/projects/20699/trigger/pipeline --data-binary @-
-
rm version_details
# Prepare and merge knapsack tests
knapsack
:
<<
:
*knapsack-state
...
...
doc/development/README.md
View file @
b667fba8
...
...
@@ -41,6 +41,7 @@
-
[
Shell commands
](
shell_commands.md
)
in the GitLab codebase
-
[
Sidekiq debugging
](
sidekiq_debugging.md
)
-
[
Object state models
](
object_state_models.md
)
-
[
Building a package for testing purposes
](
build_test_package.md
)
## Databases
...
...
doc/development/build_test_package.md
0 → 100644
View file @
b667fba8
# Building a package for testing
While developing a new feature or modifying an existing one, it is helpful if an
installable package (or a docker image) containing those changes is available
for testing. For this very purpose, a manual job is provided in the GitLab CI/CD
pipeline that can be used to trigger a pipeline in the omnibus-gitlab repository
that will create
1.
A deb package for Ubuntu 16.04, available as a build artifact, and
2.
A docker image, which is pushed to
[
Omnibus GitLab's container
registry](https://gitlab.com/gitlab-org/omnibus-gitlab/container_registry)
(images titled
`gitlab-ce`
and
`gitlab-ee`
respectively and image tag is the
commit which triggered the pipeline).
When you push a commit to either the gitlab-ce or gitlab-ee project, the
pipeline for that commit will have a
`build-package`
manual action you can
trigger.
## Specifying versions of components
If you want to create a package from a specific branch, commit or tag of any of
the GitLab components (like GitLab Workhorse, Gitaly, GitLab Pages, etc.), you
can specify the branch name, commit sha or tag in the component's respective
`*_VERSION`
file. For example, if you want to build a package that uses the
branch
`0-1-stable`
, modify the content of
`GITALY_SERVER_VERSION`
to
`0-1-stable`
and push the commit. This will create a manual job that can be
used to trigger the build.
## Specifying the branch in omnibus-gitlab repository
In scenarios where a configuration change is to be introduced and omnibus-gitlab
repository already has the necessary changes in a specific branch, you can build
a package against that branch through an environment variable named
`OMNIBUS_BRANCH`
. To do this, specify that environment variable with the name of
the branch as value in
`.gitlab-ci.yml`
and push a commit. This will create a
manual job that can be used to trigger the build.
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