Commit graph

26 commits

Author SHA1 Message Date
Lin Jen-Shin
9984f07a28 Disallow legacy trigger without a owner
Feedback:
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/11910#note_31594492
https://gitlab.com/gitlab-org/gitlab-ce/issues/30634#note_31601001
2017-06-06 18:00:34 +08:00
Lin Jen-Shin
47b93fd761 Don't check permission, only protected ref if no user 2017-06-06 02:19:47 +08:00
Lin Jen-Shin
9ecb85a4f3 Forbid creating pipeline if it's protected and
cannot create the tag if it's a tag, and
cannot merge the branch if it's a branch.
2017-06-05 23:38:06 +08:00
Kamil Trzciński
f71106425c Merge branch '25680-CI_ENVIRONMENT_URL' into 'master'
Add `$CI_ENVIRONMENT_URL` as a job variable

Closes #25680

See merge request !11695
2017-06-05 07:03:39 +00:00
Lin Jen-Shin
2fa766e107 Only deploy if environment exists; Update tests accordingly 2017-06-03 00:24:20 +08:00
Douwe Maan
94be44c568 Fix race condition between pipeline creation and MR diff_head_sha update 2017-06-01 13:31:52 -05:00
Kamil Trzcinski
161af17c1b Introduce source to pipeline entity 2017-05-31 14:17:49 +02:00
Felipe Artur
fe790c7543 Set head pipeline when creating merge requests 2017-05-29 15:37:56 -03:00
Felipe Artur
5b9e801e81 Sanity check pipeline sha before saving merge request head pipeline 2017-05-23 18:58:02 -03:00
Valery Sizov
268b1c79e9 [Spec optimization] Joining one-line 'it' blocks 2017-05-15 12:39:56 +03:00
Felipe Artur
2ccee7161a Small code improvements and add migration spec 2017-05-08 18:43:53 -03:00
Felipe Artur
4ae411ff40 Preloads head pipeline for each merge request 2017-05-08 11:24:55 -03:00
Lin Jen-Shin
f7014cd5bc Add a test to make sure it's not auto-canceling
whenever the feature is disabled in the project.
2017-04-06 03:23:36 +08:00
Rydkin Maxim
b49e79662e refactor spec 2017-04-04 21:11:25 +03:00
Rydkin Maxim
d2f2168b51 remove a pending pipeline shared example 2017-04-04 21:11:25 +03:00
Rydkin Maxim
b5c286995c fix rubocop 2017-04-04 21:11:24 +03:00
Rydkin Maxim
a4d08e6bab rename auto_canceled_by and add foreign key 2017-04-04 21:11:24 +03:00
Rydkin Maxim
40f67c1da8 more brief way of get parent commit 2017-04-04 21:11:24 +03:00
Rydkin Maxim
9bdb869a0a fix typo 2017-04-04 21:11:24 +03:00
Rydkin Maxim
c77b1cb0fb add does not cancel HEAD pipeline spec 2017-04-04 21:11:24 +03:00
Rydkin Maxim
c81ef3041e add auto-cancel for pending pipelines on branch, if they are not HEAD
fix changelog MR reference

add non-HEAD builds finder and add `created` pipelines to scope

add spec for auto-cancel non-HEAD pipelines and refactor create_pipeline_service_spec

more refactoring for spec

adds option for auto-cancel into CI/CD settings

fix spec to new configuration

fix rubocop

fix schema.rb

fix schema.rb

replace Gitlab 9.0 with 9.1 in doc

change wording on pipeline settings

added auto_canceled_by field as identifier of autocancel subject

remove unnecessary index

replace service with retry_lock

replace auto_cancel_pending_pipelines boolean setting with integer (and enum in model)

fix schema.rb

fix schema.rb

remove projekt attribute and clean up spec

clean up spec withcouple of shared examples

added spec for "It does not cancel current pipeline" scenario

add some specs to auto-cancel

add spec for another branch pipelines
2017-04-04 21:11:24 +03:00
Robert Speicher
ca9a79f620 Use :empty_project where possible in service specs 2017-03-27 20:44:09 -04:00
Z.J. van de Weg
3ebd29b538 Futher rename the CI variables 2017-03-16 08:49:01 +01:00
Luke "Jared" Bennett
ad88cf3e17
updated ci skip regex to accept underscores and hyphens 2017-02-22 11:29:18 +00:00
Nick Thomas
58486918fc Create environments when the build referencing them is created 2016-12-15 13:57:04 +00:00
Kamil Trzcinski
39203f1adf Pre-create all builds for Pipeline when a trigger is received
This change simplifies a Pipeline processing by introducing a special new status: created.
This status is used for all builds that are created for a pipeline.
We are then processing next stages and queueing some of the builds (created -> pending) or skipping them (created -> skipped).
This makes it possible to simplify and solve a few ordering problems with how previously builds were scheduled.
This also allows us to visualise a full pipeline (with created builds).

This also removes an after_touch used for updating a pipeline state parameters.
Right now in various places we explicitly call a reload_status! on pipeline to force it to be updated and saved.
2016-08-11 15:22:35 +02:00