Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
c2083b79
Commit
c2083b79
authored
Sep 23, 2016
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Limit test environment size to one project in CI
parent
52e897dd
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
10 deletions
+5
-10
.gitlab-ci.yml
.gitlab-ci.yml
+2
-2
db/fixtures/development/04_project.rb
db/fixtures/development/04_project.rb
+3
-8
No files found.
.gitlab-ci.yml
View file @
c2083b79
...
@@ -228,10 +228,10 @@ rake db:seed_fu:
...
@@ -228,10 +228,10 @@ rake db:seed_fu:
stage
:
test
stage
:
test
<<
:
*use-db
<<
:
*use-db
variables
:
variables
:
SIZE
:
"
1"
SETUP_DB
:
"
false"
SETUP_DB
:
"
false"
RAILS_ENV
:
development
RAILS_ENV
:
"
development"
script
:
script
:
-
mkdir -p /home/git/repositories
-
git clone https://gitlab.com/gitlab-org/gitlab-test.git
-
git clone https://gitlab.com/gitlab-org/gitlab-test.git
/home/git/repositories/gitlab-org/gitlab-test.git
/home/git/repositories/gitlab-org/gitlab-test.git
-
bundle exec rake db:setup db:seed_fu
-
bundle exec rake db:setup db:seed_fu
...
...
db/fixtures/development/04_project.rb
View file @
c2083b79
...
@@ -3,11 +3,11 @@ require 'sidekiq/testing'
...
@@ -3,11 +3,11 @@ require 'sidekiq/testing'
Sidekiq
::
Testing
.
inline!
do
Sidekiq
::
Testing
.
inline!
do
Gitlab
::
Seeder
.
quiet
do
Gitlab
::
Seeder
.
quiet
do
project_urls
=
[
project_urls
=
[
'https://git
hub.com/documentcloud/underscore
.git'
,
'https://git
lab.com/gitlab-org/gitlab-test
.git'
,
'https://gitlab.com/gitlab-org/gitlab-ce.git'
,
'https://gitlab.com/gitlab-org/gitlab-ce.git'
,
'https://gitlab.com/gitlab-org/gitlab-ci.git'
,
'https://gitlab.com/gitlab-org/gitlab-ci.git'
,
'https://gitlab.com/gitlab-org/gitlab-shell.git'
,
'https://gitlab.com/gitlab-org/gitlab-shell.git'
,
'https://git
lab.com/gitlab-org/gitlab-test
.git'
,
'https://git
hub.com/documentcloud/underscore
.git'
,
'https://github.com/twitter/flight.git'
,
'https://github.com/twitter/flight.git'
,
'https://github.com/twitter/typeahead.js.git'
,
'https://github.com/twitter/typeahead.js.git'
,
'https://github.com/h5bp/html5-boilerplate.git'
,
'https://github.com/h5bp/html5-boilerplate.git'
,
...
@@ -38,12 +38,7 @@ Sidekiq::Testing.inline! do
...
@@ -38,12 +38,7 @@ Sidekiq::Testing.inline! do
]
]
# You can specify how many projects you need during seed execution
# You can specify how many projects you need during seed execution
size
=
if
ENV
[
'SIZE'
].
present?
size
=
ENV
[
'SIZE'
].
present?
?
ENV
[
'SIZE'
].
to_i
:
8
ENV
[
'SIZE'
].
to_i
else
8
end
project_urls
.
first
(
size
).
each_with_index
do
|
url
,
i
|
project_urls
.
first
(
size
).
each_with_index
do
|
url
,
i
|
group_path
,
project_path
=
url
.
split
(
'/'
)[
-
2
..-
1
]
group_path
,
project_path
=
url
.
split
(
'/'
)[
-
2
..-
1
]
...
...
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