Commit Graph

563 Commits

Author SHA1 Message Date
Lin Jen-Shin 9ae92b8caa Add cop to make sure we don't use ivar in a module 2017-09-18 21:23:45 +08:00
Gabriel Mazetto 2c489f8289 Refactor on namespace and repository checks and added specs 2017-09-12 06:57:22 +02:00
Gabriel Mazetto cc28abeafd Detect orphaned repositories and namespaces in any storage 2017-09-12 04:06:00 +02:00
Yorick Peterse 235b105c91
Finish migration to the new events setup
This finishes the procedure for migrating events from the old format
into the new format. Code no longer uses the old setup and the database
tables used during the migration process are swapped, with the old table
being dropped.

While the database migration can be reversed this will 1) take a lot of
time as data has to be coped around 2) won't restore data in the
"events.data" column as we have no way of restoring this.

Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/37241
2017-09-06 16:40:31 +02:00
Sean McGivern 446c7fc6f1 Merge branch 'system-checks-incoming-email' into 'master'
Move Incoming Email checks to System Checks

See merge request !14028
2017-09-06 09:02:47 +00:00
Nick Thomas 48115be509 Add a system check for the git user's custom SSH configuration 2017-09-04 18:16:31 +01:00
Gabriel Mazetto 71000b394b Refactored Incoming Email checks to use SystemCheck library 2017-09-04 04:25:58 +02:00
Lin Jen-Shin c5553ce772 Use `git update-ref --stdin -z` to delete refs 2017-08-30 22:01:23 +08:00
Maxim Rydkin 6a56bec735 replace `is_gitlab_user?` with `gitlab_user?` 2017-08-29 11:14:41 +03:00
Bob Van Landuyt d8d2b73b9f Improve bare repository import
- Allow imports into nested groups
- Make sure it sets the correct visibility level when creating new
  groups

While doing this, I moved the import into a testable class, that made
it easier to improve.
2017-08-23 13:36:37 +02:00
Gabriel Mazetto 78823675b2 Prevent using gitlab import task when hashed storage is enabled 2017-08-22 06:33:20 +02:00
Robert Speicher 4edfad9678 Enable Layout/TrailingWhitespace cop and auto-correct offenses 2017-08-15 13:44:37 -04:00
Z.J. van de Weg 6391406774
Add two more project templates
Related to !13108. Mostly this is just running the rake task and
changing the task a bit to catch cases like the project already existing
or so. The rake task moves archives to the vendor/project_template
directory, which are checked in too.
2017-08-15 12:55:54 +02:00
Jacob Vosmaer fab0c1eb80 Use existing BUNDLE_PATH for gitaly in local tests 2017-08-11 15:49:50 +02:00
Robert Speicher 420d835e5f Merge branch '36003-do-not-include-to-kernel' into 'master'
Don't include anything to Kernel only because of tasks

Closes #36003

See merge request !13380
2017-08-09 16:35:33 +00:00
Lin Jen-Shin 5d963fccab We shouldn't include utility methods everywhere 2017-08-08 23:14:29 +08:00
Lin Jen-Shin e26acdb11b Just extend main, rather than include to Kernel
Unfortunately rake doesn't have nested context,
everything just runs on a main rake object.
This is probably due to compatibility issue,
but anyway, we could just extend the object.
2017-08-08 22:20:16 +08:00
Jacob Vosmaer 5684528081 Unset BUNDLE_GEMFILE when installing Gitaly 2017-08-08 15:34:29 +02:00
Rémy Coutable feb8974cc8 Merge branch '35941-fix-testing-issue-following-gitaly-install-fix' into 'master'
Unset the `RUBYOPT` env variable before installing `gitaly-ruby`

Closes #35941 and #35967

See merge request !13313
2017-08-08 09:39:49 +00:00
Sean McGivern 4c8b666893 Merge branch 'zj-project-templates' into 'master'
Allow projects to be started from a template

Closes #32420

See merge request !13108
2017-08-07 19:24:14 +00:00
Z.J. van de Weg db65499e26
Fix last feature test for project templates 2017-08-07 15:32:43 +02:00
Z.J. van de Weg 2e6aa4f25e
After merge cleanup 2017-08-07 15:09:14 +02:00
Filipa Lacerda 3b9012871d Merge branch 'master' into zj-project-templates
* master: (623 commits)
  Fix issues with pdf-js dependencies
  fix missing changelog entries for security release on 2017-01-23
  Update top bar issues icon
  Fix pipeline icon in contextual nav for projects
  Since mysql is not a priority anymore, test it less
  Fix order of CI lint ace editor loading
  Add container registry and spam logs icons
  Fix different Markdown styles
  Backport to CE for:
  Make new dropdown dividers full width
  Fix spec
  Fix spec
  Fix spec
  Bump GITLAB_SHELL_VERSION and GITALY_VERSION to support unhiding refs
  Add changelog
  Install yarn via apt in update guides
  Use long curl options
  fix
  Add a spec for concurrent process
  Remove monkey-patched Array.prototype.first() and last() methods
  ...
2017-08-07 11:09:50 +01:00
Rémy Coutable 21937a157d
Print the setup steps and duration and fix an issue resulting in re-setuping GitLab Shell on each test run
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-08-04 17:27:50 +02:00
Rémy Coutable 201ce2cb55
Unset the RUBYOPT env variable before installing gitaly-ruby
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-08-04 16:10:52 +02:00
Rémy Coutable 805a28e6a1 Revert "Merge branch 'fix-gitaly-install' into 'master'"
This reverts commit 23c502b434, reversing
changes made to 1018ab0516.
2017-08-04 15:59:30 +02:00
Kim "BKC" Carlbäcker a92ccbcb9e Have raketask tell gitaly where to find shell 2017-08-04 13:54:41 +02:00
Rémy Coutable 6a29d3a487 Ensure we run installation Rake tasks in a clean env in TestEnv
If we call `system('rake', 'taks_name')`, `ENV['RUBYOPT']` is set to
`'-rbundler/setup'` but some tasks (e.g. `gitlab:gitaly:install` need
a clean env since they install their own Gem bundle.

Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-08-02 19:02:01 +02:00
Sean McGivern 90cb2aab38 Merge branch '28283-legacy-storage-format' into 'master'
[CE] Added Legacy Storage format

See merge request !13149
2017-08-01 12:24:24 +00:00
Z.J. van de Weg 09974de3e3
Create rake task to create project templates
First iteration, and some stuff is missing. But basically this rake task
does a clone of a project we've pointed it to. Than creates a project on
the GDK, which should be running in the background. This project is
exported, after which we move that archive to the location we need it.
We clean up by removing the generated project.

The first idea was to export the project on .com too, however than we
might run into ImportExport versions mismatch. This could've been
circumvented by checkout out an older commit locally. This however is
not needed yet, so we opted to not go this route yet, instead we will
iterate on what we got.
2017-08-01 13:00:51 +02:00
Jacob Vosmaer e99564568b CI fixes for gitaly-ruby 2017-08-01 10:48:46 +02:00
Gabriel Mazetto fb06a4d8fe Rename more path_with_namespace -> full_path or disk_path 2017-08-01 07:28:13 +02:00
Jacob Vosmaer 1631ad02fd Support the fact that Gitaly uses bundler 2017-07-27 16:35:40 +02:00
Phil Hughes 3256f6f404 Compile JS lang files before webpack compile
Closes #35615
2017-07-27 08:41:47 +01:00
Alejandro Rodríguez c9c0606297 Improve version handling on component install tasks
Fixes an issue where, when using branch versions, the component wouldn't
be updated after the first branch checkout. We also save one step, since
checking out the FETCH_HEAD with `-f` already does what `reset --hard`
did.
2017-07-20 17:30:29 -04:00
Timothy Andrew 8fa08ea3cd Implement review comments for !11963 from @adamniedzielski.
- Change double quotes to single quotes.
- Why is `OmniAuth.config.full_host` being reassigned in the integration test?
- Use `map` over `map!` to avoid `dup` in the `gitlab:info` rake task
- Other minor changes
2017-07-06 06:30:07 +00:00
Timothy Andrew 56754848dd Don't allow the `gitlab:env:info` rake task to mutate the list of omniauth providers.
- The test for `rake gitlab:env:info` executed the rake task, which mutated the
  list of omniauth providers, breaking subsequent tests relying on this list.

- I've changed the rake task to duplicate the providers list before modifying it.
2017-07-06 06:30:07 +00:00
Jacob Vosmaer 218da88e1a Enable gitaly token auth when testing 2017-06-20 17:42:54 +02:00
Alejandro Rodríguez 58821ebbb4 Stop using deprecated `path` field on Gitaly messages
This revealed an error in our configuration generation in
gitlab:gitaly:install rake task. The fix is included
2017-06-14 19:33:43 -04:00
Douwe Maan f1e4376fb9 Don't check if MailRoom is running on Omnibus 2017-06-09 10:58:11 -05:00
Nick Thomas b2800ee0c7 Add a Rake task to aid in rotating otp_key_base 2017-06-05 22:17:52 +01:00
Gabriel Mazetto d219f9a691 Fix BasicExecutor specs 2017-05-31 14:33:03 +02:00
Gabriel Mazetto 3f187751d4 Fixed and improved some existing checks and SystemCheck library 2017-05-31 14:33:03 +02:00
Gabriel Mazetto ecdbde3d95 Improve Specs and some fixes 2017-05-31 14:33:03 +02:00
Gabriel Mazetto 27e632758f Add ActiveUsers Check 2017-05-31 14:33:03 +02:00
Gabriel Mazetto 13e88c9395 Refactor gitlab:app:checks to use SystemCheck 2017-05-31 14:33:03 +02:00
Gabriel Mazetto 500e5227a0 WIP SystemCheck library for executing checks from a rake task 2017-05-31 14:33:03 +02:00
Rémy Coutable d40e1f547e Enable the Style/TrailingCommaInLiteral cop
Use the EnforcedStyleForMultiline: no_comma option.

Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-05-10 18:25:45 +02:00
Ahmad Sherif b03179b4a6 Print Go version in rake gitlab:env:info 2017-05-10 15:35:02 +02:00
Jacob Vosmaer 3960d974c3 Compile gitlab-shell go executables 2017-05-04 11:21:51 +02:00