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
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ophélie Gagnard
slapos.core
Commits
e6ab85ca
Commit
e6ab85ca
authored
Feb 10, 2015
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_cloud: Drop Non Allocated sooner (3 days)
parent
0c10aa0e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Instance_tryToGarbageCollectNonAllocatedRootTree.xml
...loud/Instance_tryToGarbageCollectNonAllocatedRootTree.xml
+3
-3
No files found.
master/bt5/slapos_cloud/SkinTemplateItem/portal_skins/slapos_cloud/Instance_tryToGarbageCollectNonAllocatedRootTree.xml
View file @
e6ab85ca
...
...
@@ -70,8 +70,8 @@ if latest_comment != \'Allocation failed: no free Computer Partition\':\n
return\n
\n
latest_edit_time = portal.portal_workflow.getInfoFor(instance, \'time\', wf_id=\'edit_workflow\')\n
if (int(DateTime()) - int(latest_edit_time)) <
6048
00:\n
# Allow
1 week
gap betweeb latest allocation try and deletion\n
if (int(DateTime()) - int(latest_edit_time)) <
2592
00:\n
# Allow
3 days
gap betweeb latest allocation try and deletion\n
return\n
\n
# Only destroy if the instance is the only one in the tree\n
...
...
@@ -96,7 +96,7 @@ hosting_subscription.requestDestroy(\n
sla_xml=hosting_subscription.getSlaXml(),\n
shared=hosting_subscription.isRootSlave(),\n
state=\'destroyed\',\n
comment="Garbage collect %s not allocated for more than
1 week
" % instance.getRelativeUrl(),\n
comment="Garbage collect %s not allocated for more than
3 days
" % instance.getRelativeUrl(),\n
)\n
hosting_subscription.archive()\n
...
...
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