Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Rafael Monnerat
slapos.core
Commits
a9236b9e
Commit
a9236b9e
authored
Oct 25, 2018
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_cloud: Set proxy roles for allow invoke it by the allocator.
parent
77322d78
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Computer_checkAndUpdateCapacityScope.py
...kins/slapos_cloud/Computer_checkAndUpdateCapacityScope.py
+3
-0
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Computer_checkAndUpdateCapacityScope.xml
...ins/slapos_cloud/Computer_checkAndUpdateCapacityScope.xml
+9
-1
No files found.
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Computer_checkAndUpdateCapacityScope.py
View file @
a9236b9e
import
json
import
json
computer
=
context
computer
=
context
portal
=
context
.
getPortalObject
()
portal
=
context
.
getPortalObject
()
from
zExceptions
import
Unauthorized
if
REQUEST
is
not
None
:
raise
Unauthorized
if
computer
.
getAllocationScope
()
not
in
[
'open/public'
,
'open/subscription'
]:
if
computer
.
getAllocationScope
()
not
in
[
'open/public'
,
'open/subscription'
]:
# Don't update non public computer
# Don't update non public computer
...
...
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Computer_checkAndUpdateCapacityScope.xml
View file @
a9236b9e
...
@@ -50,7 +50,15 @@
...
@@ -50,7 +50,15 @@
</item>
</item>
<item>
<item>
<key>
<string>
_params
</string>
</key>
<key>
<string>
_params
</string>
</key>
<value>
<string>
allocated_instance=None
</string>
</value>
<value>
<string>
allocated_instance=None, REQUEST=None
</string>
</value>
</item>
<item>
<key>
<string>
_proxy_roles
</string>
</key>
<value>
<tuple>
<string>
Manager
</string>
</tuple>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
id
</string>
</key>
<key>
<string>
id
</string>
</key>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment