summaryrefslogtreecommitdiff
path: root/spec/lib/gitlab
Commit message (Collapse)AuthorAgeFilesLines
* Log and send a system hook if a blocked user fails to loginsh-log-when-user-blockedStan Hu2018-01-141-0/+53
| | | | Closes #41633
* Merge branch 'remove-soft-removals' into 'master'Douwe Maan2018-01-116-29/+0
|\ | | | | | | | | | | | | Remove soft removals related code Closes #37447 See merge request gitlab-org/gitlab-ce!15789
| * Remove soft removals related codeYorick Peterse2018-01-086-29/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This removes all usage of soft removals except for the "pending delete" system implemented for projects. This in turn simplifies all the query plans of the models that used soft removals. Since we don't really use soft removals for anything useful there's no point in keeping it around. This _does_ mean that hard removals of issues (which only admins can do if I'm not mistaken) can influence the "iid" values, but that code is broken to begin with. More on this (and how to fix it) can be found in https://gitlab.com/gitlab-org/gitlab-ce/issues/31114. Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/37447
* | Merge branch 'feature/migrate-merged-branch-names-to-gitaly' into 'master'Rémy Coutable2018-01-111-28/+38
|\ \ | | | | | | | | | | | | | | | | | | Migrate merged_branch_names to Gitaly Closes gitaly#851 See merge request gitlab-org/gitlab-ce!16157
| * | Migrate merged_branch_names to GitalyAhmad Sherif2018-01-111-28/+38
| | | | | | | | | | | | Closes gitaly#851
* | | Merge branch 'option-disable-archive-cache' into 'master'Sean McGivern2018-01-111-0/+14
|\ \ \ | | | | | | | | | | | | | | | | Add option to disable git archive caching in workhorse See merge request gitlab-org/gitlab-ce!16325
| * | | Add option to disable git archive caching in workhorseoption-disable-archive-cacheJacob Vosmaer2018-01-091-0/+14
| | | |
* | | | Merge branch '38068-commits-count' into 'master'Yorick Peterse2018-01-114-0/+62
|\ \ \ \ | |_|/ / |/| | | | | | | | | | | | | | | | | | | Resolve "Store the number of merge request commits in merge_request_diffs.commits_count" Closes #38068 See merge request gitlab-org/gitlab-ce!16164
| * | | Denormalize commits count for merge request diffs38068-commits-countJan Provaznik2018-01-104-0/+62
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | For each MR diff an extra 'SELECT COUNT()' is executed to get number of commits for the diff. Overall time to get counts for all MR diffs may be quite expensive. To speed up loading of MR info, information about number of commits is stored in a MR diff's extra column. Closes #38068
* | | Merge branch 'zj-migrate-gitlab-project-rm-mv' into 'master'Douwe Maan2018-01-102-56/+23
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Migrate GitlabProject (re)move project endpoints Closes gitaly#873 See merge request gitlab-org/gitlab-ce!16249
| * | | Migrate GitlabProject (re)move project endpointsZeger-Jan van de Weg2018-01-092-56/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Migration is done through a small refactoring, which makes us call endpoins which are performing the same actions for namespaces. Tests are added to ensure only the project is removed that should be removed. Closes gitlab-org/gitaly#873
* | | | Fix hooks not being set up properly for bare import Rake tasksh-fix-bare-import-hooksStan Hu2018-01-091-2/+6
| |/ / |/| | | | | | | | Closes #41739
* | | Merge branch 'jej/backport-authorized-keys-to-ce' into 'master'Douwe Maan2018-01-092-11/+331
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Backport authorized_keys Closes gitlab-ee#3953 See merge request gitlab-org/gitlab-ce!16014
| * | | Fix spec in shell_spec.rbJames Edwards-Jones2018-01-081-1/+1
| | | | | | | | | | | | | | | | | | | | The spec for "#add_key does nothing" would always have passed, since the expectation was on both the wrong object and message.
| * | | Backport spec fixes in spec/lib/gitlab/shell_spec.rbValery Sizov2018-01-081-10/+12
| | | |
| * | | Backport authorized_keys_enabled defaults to true'Michael Kozono2018-01-081-0/+212
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Originally from branch 'fix-authorized-keys-enabled-default-2738' via merge request https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/2240 Removed background migrations which were intended to fix state after using Gitlab without a default having been set Squashed commits: Locally, if Spring was not restarted, `current_application_settings` was still cached, which prevented the migration from editing the file. This will also ensure that any app server somehow hitting old cache data will properly default this setting regardless. Retroactively fix migration This allows us to identify customers who ran the broken migration. Their `authorized_keys_enabled` column does not have a default at this point. We will fix the column after we fix the `authorized_keys` file. Fix authorized_keys file if needed Add default to authorized_keys_enabled setting Reminder: The original migration was fixed retroactively a few commits ago, so people who did not ever run GitLab 9.3.0 already have a column that defaults to true and disallows nulls. I have tested on PostgreSQL and MySQL that it is safe to run this migration regardless. Affected customers who did run 9.3.0 are the ones who need this migration to fix the authorized_keys_enabled column. The reason for the retroactive fix plus this migration is that it allows us to run a migration in between to fix the authorized_keys file only for those who ran 9.3.0. Tweaks to address feedback Extract work into background migration Move batch-add-logic to background migration Do the work synchronously to avoid multiple workers attempting to add batches of keys at the same time. Also, make the delete portion wait until after adding is done. Do read and delete work in background migration Fix Rubocop offenses Add changelog entry Inform the user of actions taken or not taken Prevent unnecessary `select`s and `remove_key`s Add logs for action taken Fix optimization Reuse `Gitlab::ShellAdapter` Guarantee the earliest key Fix migration spec for MySQL
| * | | Backport option to disable writing to `authorized_keys` fileMichael Kozono2018-01-081-11/+99
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Originally branch 'mk-toggle-writing-to-auth-keys-1631' See merge request !2004 Squashed commits: Add authorized_keys_enabled to Application Settings Ensure default settings are exposed in UI Without this change, `authorized_keys_enabled` is unchecked when it is nil, even if it should be checked by default. Add “Speed up SSH operations” documentation Clarify the reasons for disabling writes Add "How to go back" section Tweak copy Update Application Setting screenshot
| * | | Backport authorized_keys branch 'find-key-by-fingerprint'Pablo Carranza2018-01-081-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add find key by base64 key or fingerprint to the internal API See merge request !250 Squashed changes: Add unique index to fingerprint Add new index to schema Add internal api to get ssh key by fingerprint Change API endpoint to authorized_keys Add InsecureKeyFingerprint that calculates the fingerprint without shelling out Add require for gitlab key fingerprint Remove uniqueness of fingerprint index Remove unique option from migration Fix spec style in fingerprint test Fix rubocop complain Extract insecure key fingerprint to separate file Change migration to support building index concurrently Remove those hideous tabs
* | | | Merge branch 'check-environment-regex-ce' into 'master'Grzegorz Bizon2018-01-091-1/+2
|\ \ \ \ | |_|/ / |/| | | | | | | | | | | | | | | | | | | Backport "Fix environment scope regex" to CE Closes gitlab-ee#4308 See merge request gitlab-org/gitlab-ce!15945
| * | | Add speccheck-environment-regex-ceShinya Maeda2018-01-081-1/+2
| | | |
* | | | Merge branch '41683-timeout-is-not-set-for-gitaly-fetch_remote-calls' into ↵Stan Hu2018-01-081-2/+18
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 'master' Resolve "Timeout is not set for gitaly fetch_remote calls" Closes #41683 See merge request gitlab-org/gitlab-ce!16245
| * | | | Pass timeout to RepositoryService.FetchRemote Gitaly RPC calls41683-timeout-is-not-set-for-gitaly-fetch_remote-callsAlejandro Rodríguez2018-01-051-2/+18
| | | | |
* | | | | Merge branch 'delay-background-migrations' into 'master'Rémy Coutable2018-01-082-5/+20
|\ \ \ \ \ | |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | Run background migrations with a minimum interval Closes #41624 See merge request gitlab-org/gitlab-ce!16230
| * | | | Run background migrations with a minimum intervaldelay-background-migrationsYorick Peterse2018-01-052-5/+20
| | |_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds a minimum interval to BackgroundMigrationWorker, ensuring background migrations of the same class only run once every 5 minutes. This prevents a thundering herd problem where scheduled migrations all run at once due to their delays having been expired (e.g. as the result of a queue being paused for a long time). If a job was recently executed it's rescheduled with a delay that equals the remaining time of the job's lease. This means that if the lease expires in two minutes we only need to wait two minutes, instead of five. Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/41624
* | | | Merge branch 'remove-commit-tree' into 'master'Sean McGivern2018-01-082-3/+2
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | Remove the Commit#tree method See merge request gitlab-org/gitlab-ce!16236
| * | | | Remove the Commit#tree methodremove-commit-treeJacob Vosmaer2018-01-042-3/+2
| | | | |
* | | | | Merge branch 'gitaly-fetch-internal-remote' into 'master'Sean McGivern2018-01-082-16/+39
|\ \ \ \ \ | |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | Incorporate RemoteService.FetchInternalRemote Gitaly RPC Closes gitaly#857 See merge request gitlab-org/gitlab-ce!16140
| * | | | Incorporate RemoteService.FetchInternalRemote Gitaly RPCgitaly-fetch-internal-remoteAlejandro Rodríguez2018-01-052-16/+39
| | | | |
* | | | | Merge branch 'fix/gb/fix-import-export-restoring-associations' into 'master'Kamil Trzciński2018-01-073-354/+454
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix restoring associations with import/export Closes #41646 See merge request gitlab-org/gitlab-ce!16221
| * \ \ \ \ Merge branch 'master' into fix/gb/fix-import-export-restoring-associationsGrzegorz Bizon2018-01-0612-101/+422
| |\ \ \ \ \ | | | |_|_|/ | | |/| | | | | | | | | * master: (114 commits)
| * | | | | Assert on correctly restoring pipelines after an importGrzegorz Bizon2018-01-051-0/+4
| | | | | |
| * | | | | Fix import/export project tree saver specsGrzegorz Bizon2018-01-052-7/+19
| | | | | |
| * | | | | Assign stage and pipeline to a status when importingGrzegorz Bizon2018-01-052-360/+410
| | | | | |
| * | | | | Check if stage_id relation has been assigned onlyGrzegorz Bizon2018-01-041-1/+1
| | | | | |
| * | | | | Add test for restoring associations with import/exportGrzegorz Bizon2018-01-042-2/+36
| | | | | |
* | | | | | Fix error 500 when viewing commit and merge request diffsStan Hu2018-01-071-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Due to the refactoring in !16082, `Blob#batch` no longer falls back to a default `blob_size_limit`. Since `Repository#batch_blobs` was using a default `nil` value, this would cause issues in the `Blob#find_by_rugged` method. This fix here is to be consistent and use a non-nil default value in `Repository#batch_blobs`. The problem was masked in development and tests because Gitaly is always enabled by default for all features. Closes #41735
* | | | | | Merge branch '22643-manual-job-page' into 'master'Kamil Trzciński2018-01-061-6/+8
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Resolve "Improve non-triggered manual action job detail page" Closes #22643 and #37843 See merge request gitlab-org/gitlab-ce!15991
| * \ \ \ \ \ Merge branch 'master' into 22643-manual-job-pageFilipa Lacerda2018-01-055-16/+120
| |\ \ \ \ \ \ | | | |_|_|_|/ | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (24 commits) Allow local tests to use a modified Gitaly Update check.md add deprecation and removal issue to docs Add status attribute to runner api entity Fix typos in a code comment Just try to detect and assign once Modify `LDAP::Person` to return username value based on attributes Create Kubernetes based on Application Templates Fix a bug where charlock_holmes was used needlessly to encode strings Ignore the Migration/Datetime cop in a migration that fix a column type to datetime_with_timezone Use `__` instead of `s__` when context is not required Enclose props in quotes Update some Gitaly annotations in Gitlab::Shell Prepare Gitlab::Git::Repository#rebase for Gitaly migration add missing changelog refactor spec, add docs deprecate check integrity task add lock specs add locks chek remove max-depth flag so it works with subgroups ...
| * | | | | | Merge branch 'master' into 22643-manual-job-pageFilipa Lacerda2018-01-0443-236/+883
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (200 commits) Fix issue boards scroll config. Added multi editor setting on the profile preferences page fix missing import of timeWeek which would cause errors in prometheus graphs with deployments Remove downcase from special path helper Rename db:seed_fu-{pg,mysql} to gitlab:setup-{pg,mysql} Fix error when viewing diffs without blobs Moves prettier to dev dependency Eager load event target authors whenever possible Do not run ee_compat_check on security branches Include integration tests in CE/EE testing documentation 41054-Disallow creation of new Kubernetes integrations Resolve "Resizable file list and commit panel" Make tooltip placement bottom by default as per design guidelines Fix groups list icon, timestamp alignment and row height Avoid leaving a push event empty if payload cannot be created Move git operations for UpdateRemoteMirrorService into Gitlab::Git Move delete_remote_branches from Gitlab::Shell to Gitlab::Git::Repository Move push_remote_branches from Gitlab::Shell to Gitlab::Git::Repository Update Kubernetes service documentation fix issue #37843 ...
| * | | | | | | Fix cycle analytics specsGrzegorz Bizon2018-01-041-6/+8
| | | | | | | |
* | | | | | | | Merge branch 'master' into 41249-clearing-the-cacheMatija Čupić2018-01-057-29/+160
|\ \ \ \ \ \ \ \ | | |_|_|_|/ / / | |/| | | | | |
| * | | | | | | Use --left-right and --max-count for counting diverging commitsLin Jen-Shin (godfat)2018-01-051-1/+39
| | | | | | | |
| * | | | | | | Merge branch 'ce-backport=reorder-issues' into 'master'Sean McGivern2018-01-051-12/+1
| |\ \ \ \ \ \ \ | | |_|_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | CE Backport of reordering issues in epics See merge request gitlab-org/gitlab-ce!16247
| | * | | | | | Refactor matchers for background migrationsce-backport=reorder-issuesJarka Kadlecová2018-01-051-12/+1
| | | | | | | |
| * | | | | | | Merge branch 'zj-blob-batch' into 'master'Douwe Maan2018-01-051-11/+4
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reroute batch blobs to single blob RPC See merge request gitlab-org/gitlab-ce!16082
| | * | | | | | | Reroute batch blobs to single blob RPCZeger-Jan van de Weg2018-01-021-11/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Given the priorities shifted for the Gitaly team, this endpoint does not get a dedicated endpoint yet. To make it work in a cloud native environment the request needs to go to Gitaly, not rugged. This is achieved by rerouting to the generic TreeEntry endpoint.
| * | | | | | | | Merge branch 'ldap_username_attributes' into 'master'Douwe Maan2018-01-053-5/+98
| |\ \ \ \ \ \ \ \ | | |_|/ / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Modify `LDAP::Person` to return username value based on attributes Closes #39691 See merge request gitlab-org/gitlab-ce!15286
| | * | | | | | | Modify `LDAP::Person` to return username value based on attributesDrew Blessing2018-01-043-5/+98
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `Gitlab::LDAP::Person` did not respect the LDAP attributes username configuration and would simply return the uid value. There are cases where users would like to specify a different username field to allow more friendly GitLab usernames. For example, it's common in AD to have sAMAccountName be an employee ID like `A12345` while the local part of the email address is more human-friendly.
| * | | | | | | | Fix a bug where charlock_holmes was used needlessly to encode strings41677-branch-name-omitted-due-to-bad-utf-8-conversion-by-gitaly-ref-handlerAlejandro Rodríguez2018-01-041-0/+18
| | |_|_|/ / / / | |/| | | | | |
* | | | | | | | Rename cache_index in safe_model_attributesMatija Čupić2018-01-051-1/+1
| | | | | | | |