Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Tristan Cavelier
erp5
Commits
121d0f2c
Commit
121d0f2c
authored
May 10, 2011
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not use abstract name for storage.
parent
fc13350c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
9 deletions
+5
-9
slapos/recipe/erp5/src/slapos/recipe/erp5/__init__.py
slapos/recipe/erp5/src/slapos/recipe/erp5/__init__.py
+5
-9
No files found.
slapos/recipe/erp5/src/slapos/recipe/erp5/__init__.py
View file @
121d0f2c
...
@@ -513,8 +513,6 @@ class Recipe(BaseSlapRecipe):
...
@@ -513,8 +513,6 @@ class Recipe(BaseSlapRecipe):
zeo_number
=
0
zeo_number
=
0
for
zeo_server
in
sorted
(
self
.
_zeo_storage_dict
.
iterkeys
()):
for
zeo_server
in
sorted
(
self
.
_zeo_storage_dict
.
iterkeys
()):
zeo_number
+=
1
zeo_number
+=
1
server_dir
=
os
.
path
.
join
(
zodb_dir
,
str
(
zeo_number
))
self
.
_createDirectory
(
server_dir
)
zeo_event_log
=
os
.
path
.
join
(
self
.
log_directory
,
'zeo-%s.log'
%
zeo_number
)
zeo_event_log
=
os
.
path
.
join
(
self
.
log_directory
,
'zeo-%s.log'
%
zeo_number
)
zeo_pid
=
os
.
path
.
join
(
self
.
run_directory
,
'zeo-%s.pid'
%
zeo_number
)
zeo_pid
=
os
.
path
.
join
(
self
.
run_directory
,
'zeo-%s.pid'
%
zeo_number
)
self
.
registerLogRotation
(
'zeo-%s'
%
zeo_number
,
[
zeo_event_log
],
self
.
registerLogRotation
(
'zeo-%s'
%
zeo_number
,
[
zeo_event_log
],
...
@@ -525,11 +523,9 @@ class Recipe(BaseSlapRecipe):
...
@@ -525,11 +523,9 @@ class Recipe(BaseSlapRecipe):
zeo_event_log
=
zeo_event_log
,
zeo_event_log
=
zeo_event_log
,
zeo_pid
=
zeo_pid
,
zeo_pid
=
zeo_pid
,
)
)
storage_number
=
0
storage_definition_list
=
[]
storage_definition_list
=
[]
for
storage_name
in
sorted
(
self
.
_zeo_storage_dict
[
zeo_server
]):
for
storage_name
in
sorted
(
self
.
_zeo_storage_dict
[
zeo_server
]):
storage_number
+=
1
path
=
os
.
path
.
join
(
zodb_dir
,
'%s.fs'
%
storage_name
)
path
=
os
.
path
.
join
(
server_dir
,
'zodb_%s.fs'
%
storage_number
)
storage_definition_list
.
append
(
"""<filestorage %(storage_name)s>
storage_definition_list
.
append
(
"""<filestorage %(storage_name)s>
path %(path)s
path %(path)s
</filestorage>"""
%
dict
(
storage_name
=
storage_name
,
path
=
path
))
</filestorage>"""
%
dict
(
storage_name
=
storage_name
,
path
=
path
))
...
@@ -563,12 +559,12 @@ class Recipe(BaseSlapRecipe):
...
@@ -563,12 +559,12 @@ class Recipe(BaseSlapRecipe):
# it is time to fill known_tid_storage_identifier_dict with backup
# it is time to fill known_tid_storage_identifier_dict with backup
# destination
# destination
formatted_storage_dict
=
dict
()
formatted_storage_dict
=
dict
()
for
k
,
v
in
known_tid_storage_identifier_dict
.
copy
().
iteritems
():
for
k
ey
,
v
in
known_tid_storage_identifier_dict
.
copy
().
iteritems
():
# generate unique name for each backup
# generate unique name for each backup
name
=
'_'
.
join
([
'_'
.
join
([
str
(
q
)
for
q
in
k
[
0
][
0
]]),
k
[
1
]])
storage_name
=
key
[
1
]
destination
=
os
.
path
.
join
(
backup_base_path
,
name
)
destination
=
os
.
path
.
join
(
backup_base_path
,
storage_
name
)
self
.
_createDirectory
(
destination
)
self
.
_createDirectory
(
destination
)
formatted_storage_dict
[
str
(
k
)]
=
(
v
[
0
],
destination
,
v
[
1
])
formatted_storage_dict
[
str
(
k
ey
)]
=
(
v
[
0
],
destination
,
v
[
1
])
logfile
=
os
.
path
.
join
(
self
.
log_directory
,
'tidstorage.log'
)
logfile
=
os
.
path
.
join
(
self
.
log_directory
,
'tidstorage.log'
)
pidfile
=
os
.
path
.
join
(
self
.
run_directory
,
'tidstorage.pid'
)
pidfile
=
os
.
path
.
join
(
self
.
run_directory
,
'tidstorage.pid'
)
statusfile
=
os
.
path
.
join
(
self
.
log_directory
,
'tidstorage.tid'
)
statusfile
=
os
.
path
.
join
(
self
.
log_directory
,
'tidstorage.tid'
)
...
...
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