From e2656444e8dcdb0d37351ea7ac70ebb067bb2d7f Mon Sep 17 00:00:00 2001
From: Anita Kuno <anteaya@anteaya.info>
Date: Thu, 19 Jun 2014 18:24:13 -0400
Subject: [PATCH] Bring some uniformity to olso acl files

Currently oslo acl files do different things. When one is looking
at the files for examples of how oslo project permissions work as
a way of evaluating new oslo acl files, there is some confusion.
This patch brings the olso acl files into a common alignment,
providing a template for future oslo acl file structure. It also removes
tagging ACLs from the repositories that don't use tags.

The project-name-core groups have review permission in all branches.
The project-name-ptl groups have tagging permission.

This patch also edits acl files for oslo common libs: pycadf and
taskflow, as well as openstack-dev tools: cookiecutter,
oslo-cookiecutter and pbr. The permission for taskflow-core to
create branches is removed.

This patch removes the need to have the oslo-specs-core and
olso-milestone gerrit groups.

Change-Id: I5cb6948502289d8f4179aabd35885a669df9d174
---
 .../gerrit/acls/openstack-dev/cookiecutter.config      |  3 ---
 .../gerrit/acls/openstack-dev/oslo-cookiecutter.config |  3 ---
 .../files/gerrit/acls/openstack-dev/pbr.config         |  2 +-
 .../files/gerrit/acls/openstack/oslo-incubator.config  |  5 -----
 .../files/gerrit/acls/openstack/oslo-specs.config      |  6 +++---
 .../files/gerrit/acls/openstack/oslo.config.config     |  7 +------
 .../files/gerrit/acls/openstack/oslo.db.config         |  7 +------
 .../files/gerrit/acls/openstack/oslo.i18n.config       |  7 +------
 .../files/gerrit/acls/openstack/oslo.messaging.config  |  6 ++----
 .../files/gerrit/acls/openstack/oslo.rootwrap.config   |  7 +------
 .../files/gerrit/acls/openstack/oslo.version.config    |  7 +------
 .../files/gerrit/acls/openstack/oslo.vmware.config     |  2 +-
 .../files/gerrit/acls/openstack/oslosphinx.config      |  7 +------
 .../files/gerrit/acls/openstack/oslotest.config        |  7 +------
 .../files/gerrit/acls/openstack/pycadf.config          |  7 +------
 .../files/gerrit/acls/openstack/taskflow.config        | 10 ----------
 16 files changed, 15 insertions(+), 78 deletions(-)

diff --git a/modules/openstack_project/files/gerrit/acls/openstack-dev/cookiecutter.config b/modules/openstack_project/files/gerrit/acls/openstack-dev/cookiecutter.config
index fb0b7c11a3..d5587dea3a 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack-dev/cookiecutter.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack-dev/cookiecutter.config
@@ -3,9 +3,6 @@ abandon = group cookiecutter-core
 label-Code-Review = -2..+2 group cookiecutter-core
 label-Workflow = -1..+1 group cookiecutter-core
 
-[access "refs/tags/*"]
-pushSignedTag = group cookiecutter-core
-
 [receive]
 requireChangeId = true
 
diff --git a/modules/openstack_project/files/gerrit/acls/openstack-dev/oslo-cookiecutter.config b/modules/openstack_project/files/gerrit/acls/openstack-dev/oslo-cookiecutter.config
index e3763b38af..c8990d60e4 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack-dev/oslo-cookiecutter.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack-dev/oslo-cookiecutter.config
@@ -3,9 +3,6 @@ abandon = group oslo-core
 label-Code-Review = -2..+2 group oslo-core
 label-Workflow = -1..+1 group oslo-core
 
-[access "refs/tags/*"]
-pushSignedTag = group oslo-core
-
 [receive]
 requireChangeId = true
 requireContributorAgreement = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack-dev/pbr.config b/modules/openstack_project/files/gerrit/acls/openstack-dev/pbr.config
index 823307e9b6..e9990cd4f3 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack-dev/pbr.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack-dev/pbr.config
@@ -4,7 +4,7 @@ label-Code-Review = -2..+2 group pbr-core
 label-Workflow = -1..+1 group pbr-core
 
 [access "refs/tags/*"]
-pushSignedTag = group pbr-core
+pushSignedTag = group pbr-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslo-incubator.config b/modules/openstack_project/files/gerrit/acls/openstack/oslo-incubator.config
index 1958dfadec..c8990d60e4 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslo-incubator.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslo-incubator.config
@@ -3,11 +3,6 @@ abandon = group oslo-core
 label-Code-Review = -2..+2 group oslo-core
 label-Workflow = -1..+1 group oslo-core
 
-[access "refs/heads/proposed/*"]
-abandon = group oslo-milestone
-label-Code-Review = -2..+2 group oslo-milestone
-label-Workflow = -1..+1 group oslo-milestone
-
 [receive]
 requireChangeId = true
 requireContributorAgreement = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslo-specs.config b/modules/openstack_project/files/gerrit/acls/openstack/oslo-specs.config
index e28775886c..c8990d60e4 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslo-specs.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslo-specs.config
@@ -1,7 +1,7 @@
 [access "refs/heads/*"]
-abandon = group oslo-specs-core
-label-Code-Review = -2..+2 group oslo-specs-core
-label-Workflow = -1..+1 group oslo-specs-core
+abandon = group oslo-core
+label-Code-Review = -2..+2 group oslo-core
+label-Workflow = -1..+1 group oslo-core
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslo.config.config b/modules/openstack_project/files/gerrit/acls/openstack/oslo.config.config
index dc196bb0b3..2e4c4c12a4 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslo.config.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslo.config.config
@@ -3,13 +3,8 @@ abandon = group oslo-core
 label-Code-Review = -2..+2 group oslo-core
 label-Workflow = -1..+1 group oslo-core
 
-[access "refs/heads/proposed/*"]
-abandon = group oslo-milestone
-label-Code-Review = -2..+2 group oslo-milestone
-label-Workflow = -1..+1 group oslo-milestone
-
 [access "refs/tags/*"]
-pushSignedTag = group oslo-core
+pushSignedTag = group oslo-config-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslo.db.config b/modules/openstack_project/files/gerrit/acls/openstack/oslo.db.config
index 3692a61d37..95a4661a94 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslo.db.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslo.db.config
@@ -3,13 +3,8 @@ abandon = group oslo-db-core
 label-Code-Review = -2..+2 group oslo-db-core
 label-Workflow = -1..+1 group oslo-db-core
 
-[access "refs/heads/proposed/*"]
-abandon = group oslo-milestone
-label-Code-Review = -2..+2 group oslo-milestone
-label-Workflow = -1..+1 group oslo-milestone
-
 [access "refs/tags/*"]
-pushSignedTag = group oslo-db-core
+pushSignedTag = group oslo-db-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslo.i18n.config b/modules/openstack_project/files/gerrit/acls/openstack/oslo.i18n.config
index 3cf6100765..adc8696ef8 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslo.i18n.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslo.i18n.config
@@ -3,13 +3,8 @@ abandon = group oslo-i18n-core
 label-Code-Review = -2..+2 group oslo-i18n-core
 label-Workflow = -1..+1 group oslo-i18n-core
 
-[access "refs/heads/proposed/*"]
-abandon = group oslo-milestone
-label-Code-Review = -2..+2 group oslo-milestone
-label-Workflow = -1..+1 group oslo-milestone
-
 [access "refs/tags/*"]
-pushSignedTag = group oslo-milestone
+pushSignedTag = group oslo-i18n-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslo.messaging.config b/modules/openstack_project/files/gerrit/acls/openstack/oslo.messaging.config
index 81c81f752b..637b6d6dca 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslo.messaging.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslo.messaging.config
@@ -3,10 +3,8 @@ abandon = group oslo-messaging-core
 label-Code-Review = -2..+2 group oslo-messaging-core
 label-Workflow = -1..+1 group oslo-messaging-core
 
-[access "refs/heads/proposed/*"]
-abandon = group oslo-milestone
-label-Code-Review = -2..+2 group oslo-milestone
-label-Workflow = -1..+1 group oslo-milestone
+[access "refs/tags/*"]
+pushSignedTag = group olso-messaging-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslo.rootwrap.config b/modules/openstack_project/files/gerrit/acls/openstack/oslo.rootwrap.config
index d0e68aac9c..b1c8653408 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslo.rootwrap.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslo.rootwrap.config
@@ -3,13 +3,8 @@ abandon = group oslo-rootwrap-core
 label-Code-Review = -2..+2 group oslo-rootwrap-core
 label-Workflow = -1..+1 group oslo-rootwrap-core
 
-[access "refs/heads/proposed/*"]
-abandon = group oslo-rootwrap-milestone
-label-Code-Review = -2..+2 group oslo-rootwrap-milestone
-label-Workflow = -1..+1 group oslo-rootwrap-milestone
-
 [access "refs/tags/*"]
-pushSignedTag = group oslo-rootwrap-core
+pushSignedTag = group oslo-rootwrap-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslo.version.config b/modules/openstack_project/files/gerrit/acls/openstack/oslo.version.config
index dc196bb0b3..7169efd27f 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslo.version.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslo.version.config
@@ -3,13 +3,8 @@ abandon = group oslo-core
 label-Code-Review = -2..+2 group oslo-core
 label-Workflow = -1..+1 group oslo-core
 
-[access "refs/heads/proposed/*"]
-abandon = group oslo-milestone
-label-Code-Review = -2..+2 group oslo-milestone
-label-Workflow = -1..+1 group oslo-milestone
-
 [access "refs/tags/*"]
-pushSignedTag = group oslo-core
+pushSignedTag = group oslo-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslo.vmware.config b/modules/openstack_project/files/gerrit/acls/openstack/oslo.vmware.config
index 42c005c72f..4c0ff4dbd2 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslo.vmware.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslo.vmware.config
@@ -4,7 +4,7 @@ label-Code-Review = -2..+2 group oslo-vmware-core
 label-Workflow = -1..+1 group oslo-vmware-core
 
 [access "refs/tags/*"]
-pushSignedTag = group oslo-vmware-milestone
+pushSignedTag = group oslo-vmware-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslosphinx.config b/modules/openstack_project/files/gerrit/acls/openstack/oslosphinx.config
index dc196bb0b3..7169efd27f 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslosphinx.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslosphinx.config
@@ -3,13 +3,8 @@ abandon = group oslo-core
 label-Code-Review = -2..+2 group oslo-core
 label-Workflow = -1..+1 group oslo-core
 
-[access "refs/heads/proposed/*"]
-abandon = group oslo-milestone
-label-Code-Review = -2..+2 group oslo-milestone
-label-Workflow = -1..+1 group oslo-milestone
-
 [access "refs/tags/*"]
-pushSignedTag = group oslo-core
+pushSignedTag = group oslo-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/oslotest.config b/modules/openstack_project/files/gerrit/acls/openstack/oslotest.config
index dc196bb0b3..7169efd27f 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/oslotest.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/oslotest.config
@@ -3,13 +3,8 @@ abandon = group oslo-core
 label-Code-Review = -2..+2 group oslo-core
 label-Workflow = -1..+1 group oslo-core
 
-[access "refs/heads/proposed/*"]
-abandon = group oslo-milestone
-label-Code-Review = -2..+2 group oslo-milestone
-label-Workflow = -1..+1 group oslo-milestone
-
 [access "refs/tags/*"]
-pushSignedTag = group oslo-core
+pushSignedTag = group oslo-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/pycadf.config b/modules/openstack_project/files/gerrit/acls/openstack/pycadf.config
index ecbbbcb213..a8a1c9c8e6 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/pycadf.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/pycadf.config
@@ -3,13 +3,8 @@ abandon = group pycadf-core
 label-Code-Review = -2..+2 group pycadf-core
 label-Workflow = -1..+1 group pycadf-core
 
-[access "refs/heads/proposed/*"]
-abandon = group pycadf-milestone
-label-Code-Review = -2..+2 group pycadf-milestone
-label-Workflow = -1..+1 group pycadf-milestone
-
 [access "refs/tags/*"]
-pushSignedTag = group pycadf-core
+pushSignedTag = group pycadf-ptl
 
 [receive]
 requireChangeId = true
diff --git a/modules/openstack_project/files/gerrit/acls/openstack/taskflow.config b/modules/openstack_project/files/gerrit/acls/openstack/taskflow.config
index de5e185621..05849bc593 100644
--- a/modules/openstack_project/files/gerrit/acls/openstack/taskflow.config
+++ b/modules/openstack_project/files/gerrit/acls/openstack/taskflow.config
@@ -1,18 +1,8 @@
-[access "refs/*"]
-create = group taskflow-core
-
 [access "refs/heads/*"]
 abandon = group taskflow-core
 label-Code-Review = -2..+2 group taskflow-core
 label-Workflow = -1..+1 group taskflow-core
 
-[access "refs/heads/stable/*"]
-abandon = group taskflow-core
-exclusiveGroupPermissions = abandon label-Code-Review label-Workflow
-label-Code-Review = -2..+2 group taskflow-core
-label-Code-Review = -1..+1 group Registered Users
-label-Workflow = -1..+1 group taskflow-core
-
 [access "refs/tags/*"]
 pushSignedTag = group taskflow-ptl