~launchpad-pqm/launchpad/devel

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
<!-- Copyright 2010 Canonical Ltd.  This software is licensed under the
     GNU Affero General Public License version 3 (see the file LICENSE).
-->

<configure
    xmlns="http://namespaces.zope.org/zope"
    xmlns:browser="http://namespaces.zope.org/browser"
    xmlns:i18n="http://namespaces.zope.org/i18n"
    xmlns:webservice="http://namespaces.canonical.com/webservice"
    xmlns:xmlrpc="http://namespaces.zope.org/xmlrpc"
    i18n_domain="launchpad">
    <include package=".browser"/>

    <!-- Builder -->
    <class
        class="lp.buildmaster.model.builder.Builder">
        <allow
            interface="lp.buildmaster.interfaces.builder.IBuilder"/>
        <allow
            interface="lp.soyuz.interfaces.buildrecords.IHasBuildRecords"/>
        <require
            permission="launchpad.Edit"
            set_schema="lp.buildmaster.interfaces.builder.IBuilder"/>
    </class>


    <!-- BuilderSet -->
    <securedutility
        class="lp.buildmaster.model.builder.BuilderSet"
        provides="lp.buildmaster.interfaces.builder.IBuilderSet">
        <allow
            interface="lp.buildmaster.interfaces.builder.IBuilderSet"/>
    </securedutility>
    <adapter
        provides="canonical.launchpad.webapp.interfaces.IBreadcrumb"
        for="lp.buildmaster.interfaces.builder.IBuilder"
        factory="canonical.launchpad.webapp.breadcrumb.TitleBreadcrumb"
        permission="zope.Public"/>
    <adapter
        provides="canonical.launchpad.webapp.interfaces.IBreadcrumb"
        for="lp.buildmaster.interfaces.builder.IBuilderSet"
        factory="lp.soyuz.browser.builder.BuilderSetBreadcrumb"
        permission="zope.Public"/>


    <!-- BuildFarmJob -->
    <class
        class="lp.buildmaster.model.buildfarmjob.BuildFarmJob">
        <allow
            interface="lp.buildmaster.interfaces.buildfarmjob.IBuildFarmJob" />
        <require
            permission="launchpad.Edit"
            set_attributes="status"/>
        <require
            permission="launchpad.Admin"
            set_attributes="failure_count"/>
    </class>
    <securedutility
        component="lp.buildmaster.model.buildfarmjob.BuildFarmJob"
        provides="lp.buildmaster.interfaces.buildfarmjob.IBuildFarmJobSource">

        <allow
            interface="lp.buildmaster.interfaces.buildfarmjob.IBuildFarmJobSource" />
    </securedutility>
    <securedutility
        class="lp.buildmaster.model.buildfarmjob.BuildFarmJobSet"
        provides="lp.buildmaster.interfaces.buildfarmjob.IBuildFarmJobSet">
        <allow
            interface="lp.buildmaster.interfaces.buildfarmjob.IBuildFarmJobSet" />
    </securedutility>

    <!-- PackageBuild -->
    <class
        class="lp.buildmaster.model.packagebuild.PackageBuild">
        <allow
            interface="lp.buildmaster.interfaces.packagebuild.IPackageBuild" />
        <require
            permission="launchpad.Edit"
            set_attributes="dependencies"/>
    </class>

    <securedutility
        component="lp.buildmaster.model.packagebuild.PackageBuild"
        provides="lp.buildmaster.interfaces.packagebuild.IPackageBuildSource">
        <allow
            interface="lp.buildmaster.interfaces.packagebuild.IPackageBuildSource" />
    </securedutility>
    <securedutility
        class="lp.buildmaster.model.packagebuild.PackageBuildSet"
        provides="lp.buildmaster.interfaces.packagebuild.IPackageBuildSet">
        <allow
            interface="lp.buildmaster.interfaces.packagebuild.IPackageBuildSet" />
    </securedutility>

    <!-- BuildQueue -->
    <class
        class="lp.buildmaster.model.buildqueue.BuildQueue">
        <allow
            interface="lp.buildmaster.interfaces.buildqueue.IBuildQueue"/>

        <!-- XXX cprov 2005-10-20 bug=3580:
             We need a autobuild celebrity. -->
        <!-- Grant permissions to write on BuildQueue and Build. -->
        <require
            permission="zope.Public"
            set_attributes="lastscore estimated_duration builder logtail date_started"/>
    </class>


    <!-- BuildQueueSet -->
    <securedutility
        class="lp.buildmaster.model.buildqueue.BuildQueueSet"
        provides="lp.buildmaster.interfaces.buildqueue.IBuildQueueSet">
        <allow
            interface="lp.buildmaster.interfaces.buildqueue.IBuildQueueSet"/>
    </securedutility>

    <webservice:register module="lp.buildmaster.interfaces.webservice" />

</configure>