summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xgrandlyon/scripts/copy-wcs.py8
1 files changed, 1 insertions, 7 deletions
diff --git a/grandlyon/scripts/copy-wcs.py b/grandlyon/scripts/copy-wcs.py
index 24a5831..e80b5b1 100755
--- a/grandlyon/scripts/copy-wcs.py
+++ b/grandlyon/scripts/copy-wcs.py
@@ -45,13 +45,7 @@ for object_type in ('carddefs', 'formdefs', 'workflows', 'categories', 'datasour
else:
print('missing source tenant')
sys.exit(1)
- if os.path.exists('/var/lib/wcs/%s' % dest_site):
- dest_base_dir = '/var/lib/wcs/%s' % dest_site
- elif os.path.exists('/var/lib/wcs/tenants/%s' % dest_site):
- dest_base_dir = '/var/lib/wcs/tenants/%s' % dest_site
- else:
- print('missing destination tenant')
- sys.exit(1)
+ dest_base_dir = get_publisher().app_dir
orig_dir = os.path.join('%s/%s/' % (orig_base_dir, object_type))
dest_dir = os.path.join('%s/%s/' % (dest_base_dir, object_type))
if not os.path.exists(orig_dir):