Commit Graph

40 Commits

Author SHA1 Message Date
GitLab Bot 0f8c2334f0 Add latest changes from gitlab-org/gitlab@master 2020-01-23 06:08:32 +00:00
James Lopez 1c8af321dd Improve GitLab Import rake task to work with Hashed Storage and Subgroups 2017-11-07 19:11:42 +00: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
Alejandro Rodríguez 0b9d56f960 Update storage settings to allow extra values per shard
This will be necessary when adding gitaly settings. This version
doesn't make any functional changes, but allows us to include this
breaking change in 9.0 and add the needed extra settings in the future
with backwards compatibility
2017-03-03 12:13:30 -03:00
Douwe Maan 87c9df29ce Don’t exclude some file in lib from rubocop 2017-02-23 09:32:42 -06:00
Dmitriy Zaporozhets 7dc8b6b204 Merge branch 'fwn-to-find-by-full-path' into 'master'
replace `find_with_namespace` with `find_by_full_path`

See merge request !8949
2017-02-03 11:23:21 +00:00
Adam Pahlevi a0586dbc16 replace `find_with_namespace` with `find_by_full_path`
add complete changelog for !8949
2017-02-03 07:14:04 +07:00
Rémy Coutable 89a2438ab4
Fix wrong call to ProjectCacheWorker.perform
It's either ProjectCacheWorker#perform or
ProjectCacheWorker.perform_async!

Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-01-31 17:42:33 +01:00
Markus Koller 3ef4f74b1a
Add more storage statistics
This adds counters for build artifacts and LFS objects, and moves
the preexisting repository_size and commit_count from the projects
table into a new project_statistics table.

The counters are displayed in the administration area for projects
and groups, and also available through the API for admins (on */all)
and normal users (on */owned)

The statistics are updated through ProjectCacheWorker, which can now
do more granular updates with the new :statistics argument.
2016-12-21 16:39:49 +01:00
Alejandro Rodríguez 86359ec854 Refactor repository paths handling to allow multiple git mount points 2016-06-29 22:30:31 -04:00
Connor Shea 903946c78a
Replace colorize gem with rainbow.
Colorize is a gem licensed under the GPLv2, so we can’t use it in GitLab without relicensing GitLab under the terms of the GPL. Rainbow is licensed under the MIT license and does the exact same thing as Colorize, so Rainbow was added in place of Colorize.

The syntax is slightly different for Rainbow vs. Colorize, and was updated in accordance.

The gem is still a dependency of Spinach, so it’s included in the development/test environments, but won’t be packaged with the actual product, and therefore doesn’t require we relicense the product.

An attempt at relicensing Colorize was made, but didn’t succeed as the library owner never responded.

Rainbow library: https://github.com/sickill/rainbow
Relevant issue regarding licensing in GitLab's gems: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/3775
2016-06-03 10:37:09 -06:00
Stan Hu 1d410ac96a Update project repository size and commit count during import:repos task
Closes #3848
2015-12-08 09:08:22 -08:00
Stan Hu 3e9b612306 Check that project was actually created rather than just validated in import:repos task
Add gitlab-shell to error message to give user a clue that something may be wrong there.

Ran into this in #2082. User was told that repositories were created when they were
not due to hooks symlink being wrong.
2015-07-29 10:49:13 -07:00
Dmitriy Zaporozhets b8f12d1917 Replace GITLAB with GitLab in rake task descriptions 2015-06-23 16:52:40 +02:00
Fotis Gimian d74673fd43 Ensure that the first added admin performs repository imports 2015-05-15 13:01:10 +02:00
Dmitriy Zaporozhets d960b9aea2 Merge branch 'master' into 'master'
print validation errors when gitlab-rake gitlab:import:repos fails for project

Currently, when gitlab-rake gitlab:import:repos is not able to import a project it justs prints "Failed trying to create project" to the console. There seems to be no way to find out what exactly has failed. Since the check uses validation, it should at least print the validation issues. That might be a bit cryptic, but may be better than leaving the user in the dark completely.

See merge request !147
2015-01-20 05:03:22 +00:00
Ciro Santilli cd688a6011 Replace regex methods by string ones since faster
and more readable.
2014-12-28 23:53:27 +01:00
Robert Schilling 199029b842 Merge pull request #8158 from cirosantilli/basename-dirname-split
Merge File basename and direname into split
2014-10-25 10:35:07 +02:00
Ciro Santilli 706b6b5acb Fix import.rake failed import if project name is
also an existing namespace. E.g., when trying to import
group/root.git, that would fail if there is an user called root.
2014-10-24 17:26:33 +02:00
Ciro Santilli 9be12dd9ca Merge File basename and direname into split
Faster because only does one split in that case.
2014-10-23 23:10:54 +02:00
HerrBerg fc6a291af3 fix exclude wiki regex
the new regex allows importing repositories with repository name ending with wiki but still exclude gitlab wiki repositories
2014-10-13 16:26:35 +02:00
Marc Aubé ae5381f2cc Update import.rake
Output a message when a repo is skipped
2014-10-07 14:13:50 -04:00
Bastian Krol 239d942606 print validation errors when import fails 2014-07-09 14:49:53 +02:00
Dmitriy Zaporozhets 4d56c359d3 Merge pull request #6075 from skv-headless/remove_deprecated_finders
Remove deprecated finders
2014-01-22 11:04:56 -08:00
dosire 2ddfa882c0 Better wording of the import instructions. 2014-01-20 10:44:40 +01:00
skv a3f645ef51 Remove deprecated finders 2014-01-19 23:39:56 +04:00
Dmitriy Zaporozhets efa10c819d
Replace context with service in lib
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-01-16 20:35:21 +02:00
C. Walker 24bc3e0874 Forgot to fix the comment instructions. 2013-09-06 16:45:42 -07:00
C. Walker a9d3e6ce57 Fixed description. 2013-09-06 16:18:09 -07:00
Dmitriy Zaporozhets a6e57749dc Use native repo path for import task. Skip wiki repos 2013-08-14 12:45:17 +03:00
Robert Schilling c6464aa859 Remove gitolite repo check for import script 2013-06-23 19:00:10 +02:00
James E. Flemer 5f9d78fdff Include groups in import with import repos rake task
Expand the import glob to include `**/*.git` to find projects in groups
as well as top level projects.  Check for existing group, and create
group if needed.  Set namespace_id for imported projects.
2013-05-25 11:38:55 -06:00
Andrey Kumanyaev 67ccc8b52a Replace old hashes with new 1.9 ruby hashes (rebase) 2013-05-05 18:01:10 +04:00
Dmitriy Zaporozhets d64090b8a9 No gitolite in project any more 2013-02-11 19:16:59 +02:00
Erwan Arzur 621ca86b9e [import] - fix project import after refactoring 2013-01-22 19:07:11 +01:00
Dmitriy Zaporozhets 60038a99ca Import: Skip if not git repo 2012-12-23 00:18:39 +02:00
Dmitriy Zaporozhets fa8f834374 Fix import rake task and tests 2012-12-23 00:15:48 +02:00
Riyad Preukschas 19eb637419 Update uses of Gitolite.config.foo settings 2012-12-20 16:54:28 +01:00
Dmitriy Zaporozhets 37e39e4176 Added bare import script. Removed old unworking script 2012-10-30 13:04:56 +02:00