summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* Fix transferring of project to another group using the API.Douwe Maan2015-07-111-2/+2
|
* Merge branch 'fork_visibility_level' into 'master'Dmitriy Zaporozhets2015-07-101-0/+4
|\ | | | | | | | | | | | | | | Forks should not have more permissive visibility levels than the original https://dev.gitlab.org/gitlab/gitlabhq/issues/2286 See merge request !936
| * Fork visibility level fixfork_visibility_levelValery Sizov2015-07-061-0/+4
| |
* | Revert "api: add 'system', 'upvote', and 'downvote' fields to note queries"Stan Hu2015-07-091-3/+0
| | | | | | | | This reverts commit dd4fee5fdbda07fbc09234c4b043c3c9939a6a9b.
* | api: add 'system', 'upvote', and 'downvote' fields to note queriesBen Boeckel2015-07-091-0/+3
| |
* | Properly render plain readmeDmitriy Zaporozhets2015-07-091-0/+10
| | | | | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* | use teaspoon instead of jasmine for testing javascriptFrancesco Coda Zabetta2015-07-081-1/+1
| |
* | Merge branch 'improve-postgres-restore-cleaning' into 'master' Dmitriy Zaporozhets2015-07-073-25/+2
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | Use native Postgres database cleaning during backup restore We were using hacks to drop tables etc during a Postgres backup restore. With this change, we let pg_dump insert the DROP TABLE statements it needs at the start of the SQL dump. See merge request !1891
| * | Use native Postgres database cleaning during backup restoreJacob Vosmaer2015-07-073-25/+2
| |/ | | | | | | | | | | We were using hacks to drop tables etc during a Postgres backup restore. With this change, we let pg_dump insert the DROP TABLE statements it needs at the start of the SQL dump.
* | Merge branch 'compress-db' into 'master'Kamil TrzciƄski2015-07-071-0/+14
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | Compress database backup Restore handles both cases: uncompressed and compressed backup. As an improvement `IO.popen` can be used. /cc @jacobvosmaer See merge request !873
| * | Compress database backupKamil Trzcinski2015-07-061-0/+14
| |/
* | Merge branch 'settings-via-api' into 'master'Dmitriy Zaporozhets2015-07-073-0/+58
|\ \ | |/ |/| | | | | | | | | | | API to set application settings for admin Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> See merge request !934
| * Add tests and improve logicDmitriy Zaporozhets2015-07-061-1/+2
| | | | | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
| * Add docs and empty specs for applicaiton settings APIDmitriy Zaporozhets2015-07-061-2/+1
| | | | | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
| * API to set application settings for adminDmitriy Zaporozhets2015-07-033-0/+58
| | | | | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* | Merge pull request #9430 from gitlabhq/fix-rake-test-ciDmitriy Zaporozhets2015-07-061-1/+1
|\ \ | | | | | | Use teaspoon instead of jasmine:ci
| * | Use teaspoon instead of jasmine:ciDmitriy Zaporozhets2015-07-031-1/+1
| |/ | | | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* | Allow user to be blocked and unblocked via the APISteve Norman2015-07-031-0/+30
|/
* Extract the longest-matching ref from a commit path when multiple matches occurStan Hu2015-07-011-2/+6
| | | | Closes #1839
* Reuse HTML Pipeline object in Markdown parserKamil Trzcinski2015-06-301-2/+2
| | | | The patches reduces pressure on GC and reduces markdown processing time
* Merge branch '1791-fix-github-issue-order' into 'master'Stan Hu2015-06-291-1/+3
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix wrong order of issues when importing from github ### 1. What does this MR do? The order of issues imported from GitHub is fixed. ### 2. Are there points in the code the reviewer needs to double check? Nothing. ### 3. Why was this MR needed? The default behaviors of GitHub API at listing issues are sort: :created and direction: :desc. See GitHub API details at https://developer.github.com/v3/issues/#list-issues. ### 4. What are the relevant issue numbers / Feature requests? Fixes #1791 ### 5. Screenshots (if relevant) Nothing See merge request !898
| * Fix wrong order of issues when importing from githubHiroyuki Sato2015-06-281-1/+3
| | | | | | | | | | See API details at https://developer.github.com/v3/issues/. Refs #1791
* | Remove jasmine:ci task, execute teaspoon directly on CIrs-update-gitlab-ciRobert Speicher2015-06-281-12/+0
|/
* Merge branch 'rename-abilities' into 'master'Dmitriy Zaporozhets2015-06-264-7/+7
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rename abilities to correspond contoller/model action names write_ was renamed to create_ modify_ was renamed to update_ So now in update action we have next code ``` def create can?(current_user, :create_issue, @issue) end def update can?(current_user, :update_issue, @issue) end ``` See merge request !896
| * Rename abilities to correspond contoller/model action namesrename-abilitiesDmitriy Zaporozhets2015-06-264-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | write_ was renamed to create_ modify_ was renamed to update_ So now in update action we have next code def create can?(current_user, :create_issue, @issue) end def update can?(current_user, :update_issue, @issue) end Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* | Only people who can manage issue can assign labels to itpermission-improvementsDmitriy Zaporozhets2015-06-261-1/+1
|/ | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* Add 2FA status to user admin APIStan Hu2015-06-231-0/+1
| | | | Closes https://github.com/gitlabhq/gitlabhq/issues/9391
* Merge branch 'split-tests' into 'master'Dmitriy Zaporozhets2015-06-2321-65/+61
|\ | | | | | | | | | | | | | | Split rspec and spinach tests in parallel For https://dev.gitlab.org/gitlab/gitlabhq/issues/2386 See merge request !874
| * Replace GITLAB with GitLab in rake task descriptionsDmitriy Zaporozhets2015-06-2319-37/+37
| |
| * Refactor rake tasks for testsDmitriy Zaporozhets2015-06-232-28/+24
| |
* | Merge branch 'fix-diff-patch-public-mr' into 'master'Dmitriy Zaporozhets2015-06-232-3/+7
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix downloading of patches on public merge requests when user logged out ### What does this MR do? This MR makes it possible to download a diff patch on a public merge request when a user is logged out. ### Why was this MR needed? An Error 500 would result when a user attempted to click on the "Email Patches" or "Plain Diff" button: ``` NoMethodError - undefined method `id' for nil:NilClass: lib/gitlab/backend/shell_env.rb:9:in `set_env' lib/gitlab/satellite/action.rb:20:in `in_locked_and_timed_satellite' lib/gitlab/satellite/merge_action.rb:49:in `diff_in_satellite' app/models/merge_request.rb:219:in `to_diff' app/controllers/projects/merge_requests_controller.rb:42:in `block (2 levels) in show' ``` ### What are the relevant issue numbers? * Closes #1225 * Closes #1854 (dup) * Closes #1858 (dup) See merge request !872
| * Fix downloading of patches on public merge requests when user logged outStan Hu2015-06-232-3/+7
| | | | | | | | | | | | Closes #1225 Closes #1854 Closes #1858
* | Merge branch 'admin-edit-identities' into 'master'Dmitriy Zaporozhets2015-06-231-0/+19
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | Admin can see, edit and remove user identities Related to #1415 and https://dev.gitlab.org/gitlab/gitlabhq/issues/2224 Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> See merge request !843
| * \ Merge branch 'master' into admin-edit-identitiesDmitriy Zaporozhets2015-06-223-1/+9
| |\ \ | | |/ | | | | | | | | | | | | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> Conflicts: app/views/admin/users/show.html.haml
| * | Make provider a select for identities form in admin areaDmitriy Zaporozhets2015-06-221-0/+19
| | | | | | | | | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* | | Fix error when deleting a user who has projectsStan Hu2015-06-231-1/+1
| |/ |/| | | | | | | Closes #1856 Closes https://github.com/gitlabhq/gitlabhq/issues/9394
* | Merge branch 'nginx_defaulthost_documentation' into 'master'Dmitriy Zaporozhets2015-06-222-0/+8
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Close #178 Nginx conf default_host documentation This closes #178 We're just making it clear that some nginx installs such as by default on recent Ubuntu's, the /etc/nginx/sites-enabled/default file will conflict the listen line of the gitlab nginx conf's due to the default_server directive. changed installation.md to identify the issue to a user added notes to both nginx configs for gitlab and gitlab-ssl [ci-skip See merge request !225
| * | fixed typoLuke Ashe-Browne2014-12-031-2/+2
| | |
| * | adding notes to gitlab nginx confLuke Ashe-Browne2014-12-032-1/+9
| | | | | | | | | | | | | | | We want to make users aware that the nginx default config will conflict with the gitlab default_server conf file.
* | | Merge branch 'restore_uploads_fix' into 'master'Dmitriy Zaporozhets2015-06-221-1/+1
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid "cannot copy directory ... to itself" error on restore (on Docker?) rake gitlab:backup:restore fails for me in my Docker-hosted Gitlab-CE instance; during the restore, any existing "uploads" directory is backed up by [this code](https://gitlab.com/gitlab-org/gitlab-ce/blob/833bc30/lib/backup/uploads.rb#L23) -- ```ruby def backup_existing_uploads_dir timestamped_uploads_path = File.join(app_uploads_dir, '..', "uploads.#{Time.now.to_i}") if File.exists?(app_uploads_dir) FileUtils.mv(app_uploads_dir, timestamped_uploads_path) end end ``` When this executes for me, the ```FileUtils.mv``` parameters are "/home/git/gitlab/public/uploads" and "/home/git/gitlab/public/uploads/../uploads.1407019546"; an exception is raised, producing this double stacktrace: ``` ArgumentError: cannot copy directory /home/git/gitlab/public/uploads to itself /home/git/gitlab/public/uploads/../uploads.1407019546 /home/git/gitlab/lib/backup/uploads.rb:26:in `backup_existing_uploads_dir' /home/git/gitlab/lib/backup/uploads.rb:18:in `restore' /home/git/gitlab/lib/tasks/gitlab/backup.rake:73:in `block (4 levels) in <top (required)>' /home/git/gitlab/lib/tasks/gitlab/backup.rake:30:in `block (3 levels) in <top (required)>' Errno::EXDEV: Invalid cross-device link @ sys_fail2 - (/home/git/gitlab/public/uploads, /home/git/gitlab/public/uploads/../uploads.1407019546) /home/git/gitlab/lib/backup/uploads.rb:26:in `backup_existing_uploads_dir' /home/git/gitlab/lib/backup/uploads.rb:18:in `restore' /home/git/gitlab/lib/tasks/gitlab/backup.rake:73:in `block (4 levels) in <top (required)>' /home/git/gitlab/lib/tasks/gitlab/backup.rake:30:in `block (3 levels) in <top (required)>' Tasks: TOP => gitlab:backup:uploads:restore (See full trace by running task with --trace) ``` I'm guessing from the first message that ```mv``` walks the destination path to ensure that we're not moving the source into itself -- it doesn't get as far as interpreting the '..', but throws when it sees that the destination appears to start with the source path. The second stacktrace I have no clue about - maybe it's AUFS- or Docker-related? I attempted to reproduce this separately with the omnibus distribution in a fresh Ubuntu 14.04 install without Docker involved, and was unable to - backup and restore worked fine. I then tested my theory by FileUtils.expand_path-ing the destination in my own Docker setup code, and that made the problem go away, so that's what this merge request does. (I'm using backups created and restored on gitlab-ce 7-1-stable, at facfec4b2; this is on Ubuntu 14.04 with Docker 1.1.1) I know I'd look askance at a PR without tests for an unreproducable problem, but even if this is rejected, I'm submitting it anyway because maybe someone else will Google it and find it useful. I'm happy to do more work to improve this if you have suggestions. See merge request !165
| * | Avoid "cannot copy directory to itself" restore errorBryan Stearns2014-08-031-1/+1
| | |
* | | Fix behavior of ldap_person method in Gitlab::OAuth::UserAlex Lossent2015-06-171-4/+5
| | | | | | | | | | | | | | | Code tweaks in 45e9150a caused the ldap_person method to not return expected results. Improved tests to cover the ldap_person method, which was previously stubbed.
* | | Dont set checkout sha for removed branch/tagDmitriy Zaporozhets2015-06-151-2/+5
| | | | | | | | | | | | Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
* | | Merge branch 'update_ssl_ciphers' into 'master'Dmitriy Zaporozhets2015-06-151-1/+1
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update ssl ciphers Removing all DHE suites from Nginx template SSL ciphers. This will deny forward secrecy for Android 2.3.7, Java 6 and OpenSSL 0.9.8. but will give A+ rating on SSL labs. Google sites also do not have DHE suites, [source](https://community.qualys.com/blogs/securitylabs/2013/06/25/ssl-labs-deploying-forward-secrecy) > Google's sites, for example, tend to not have any DHE suites in their configuration. [2013] See merge request !814
| * | | Update SSL ciphers per logjam vulnerability recommendations.update_ssl_ciphersMarin Jankovski2015-06-151-1/+1
| | | |
* | | | Add Gitlab::Themes module; remove Gitlab::ThemeRobert Speicher2015-06-132-50/+67
|/ / / | | | | | | | | | | | | | | | | | | Now we can simply loop through all themes, among other things. This also removes the `dark_theme` / `light_theme` classes and the `theme_type` helper, since they weren't used anywhere.
* | | Merge branch 'feature-session-expire-seconds-ui' into 'master'Douwe Maan2015-06-121-1/+2
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add session expiration delay configuration through UI application Setting is accessible by the administrator through the UI and defaults to 1 week (the current setting) Answers the following suggestions: * http://feedback.gitlab.com/forums/176466-general/suggestions/6210719-make-session-length-configurable * http://feedback.gitlab.com/forums/176466-general/suggestions/6730512-automatic-logout-after-a-time-being-idle See merge request !774
| * | | session_expire_seconds => session_expire_delaythemaze752015-06-101-1/+1
| | | | | | | | | | | | | | | | | | | | delay is in seconds more legible code in session_store Added `GitLab restart required` help block to session_expire_delay
| * | | Add session expiration delay configuration through UI applicationEric Maziade2015-06-051-1/+2
| | | | | | | | | | | | settings
* | | | Merge branch 'note_about_omnibus_changes' into 'master'Dmitriy Zaporozhets2015-06-122-2/+14
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a note that changing example configuration files requires changing omnibus-gitlab. Keeping track of changes in these files is not easy and they usually require change in omnibus-gitlab. Added a note so everyone is aware of this. Similar is added to gitlab-shell and gitlab-ci. Discussed in gitlab-org/omnibus-gitlab#605 See merge request !800