summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dzaporozhets@gitlab.com>2015-03-31 16:10:48 +0000
committerDmitriy Zaporozhets <dzaporozhets@gitlab.com>2015-03-31 16:10:48 +0000
commit6ad6823940968ace5dddbe746a0477f6bd4b4a43 (patch)
tree9860280ab15db0f5d77b0e3fdd0fd73eb573ff7a
parent9e8e51d21e14b065491062eea3244cd755bff5f8 (diff)
parent9437042282b098b25982e8bff6a3d4d156b9a28f (diff)
downloadgitlab-ci-6ad6823940968ace5dddbe746a0477f6bd4b4a43.tar.gz
Merge branch 'shared_runners' into 'master'
Shared_runners_enabled = false if there are assigned runners https://gitlab.com/gitlab-org/gitlab-ci/issues/129 https://dev.gitlab.org/gitlab/gitlab-ci/issues/181 https://dev.gitlab.org/gitlab/gitlab-ci/issues/182 See merge request !148
-rw-r--r--CHANGELOG3
-rw-r--r--db/migrate/20150330001111_disable_shared_runners.rb8
-rw-r--r--db/schema.rb2
3 files changed, 12 insertions, 1 deletions
diff --git a/CHANGELOG b/CHANGELOG
index 2a02c06..fb5015e 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -2,6 +2,9 @@ v7.10.0
- Projects sorting by last commit date
- Add project search at runner page
+v7.9.2
+ - [Security] Already existing projects should not be served by shared runners
+
v7.9.1
- [Security] Adding explicit is_shared parameter to runner
- [Security] By default new projects are not served by shared runners
diff --git a/db/migrate/20150330001111_disable_shared_runners.rb b/db/migrate/20150330001111_disable_shared_runners.rb
new file mode 100644
index 0000000..dbb32ba
--- /dev/null
+++ b/db/migrate/20150330001111_disable_shared_runners.rb
@@ -0,0 +1,8 @@
+class DisableSharedRunners < ActiveRecord::Migration
+ def up
+ execute("UPDATE projects SET shared_runners_enabled = false WHERE id IN (SELECT project_id FROM runner_projects)");
+ end
+
+ def down
+ end
+end
diff --git a/db/schema.rb b/db/schema.rb
index f066143..e194f7a 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -11,7 +11,7 @@
#
# It's strongly recommended that you check this file into your version control system.
-ActiveRecord::Schema.define(version: 20150324001227) do
+ActiveRecord::Schema.define(version: 20150330001111) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"