[opencms-dev] Import resources, replace all existing content

Honey.Bhandari at cognizant.com Honey.Bhandari at cognizant.com
Tue Sep 12 08:54:59 CEST 2017


Try doing this -
1. Export from authoring envt as a module
2. Use ImportModule to import the exported module.

Regards
Honey
________________________________________
From: opencms-dev-bounces at opencms.org [opencms-dev-bounces at opencms.org] on behalf of Asger K. Jensen [akj at tmnet.dk]
Sent: Tuesday, September 12, 2017 12:12 PM
To: opencms-dev at opencms.org
Subject: [opencms-dev] Import resources, replace all existing content

Hi,
Using OpenCMS 10.5.0

We currently work with two environments: Authoring and Live. Users make changes in Authoring (internally) and publish it locally. A scheduled job then runs that export all resources from /sites/default to a file, and this file is then transferred to the live system, where it is imported again, using the "importResource" command from OpenCMS CLI, after which it is published to make it available.

This works well, except for 3 things:
1) Any asset that is moved/renamed in the source system gets silently ignored by the importResource call

2) Any assets that are deleted in the source system does not get reflected during exportResource.

3) We are accruing new versions in Live on every import.


We have looked at the Enterprise module, but that publishes to Live immediatly upon publish in authoring, and we need changes to go out bulk(to be in lockstep with data from other systema), and with no direct access between the systems.


Point 1) is probably the biggest issue.

Is there any way to specify for importResource that it is a complete import, and that it should (transactionally) do a delete-all first, before importing the resources?


Sent from my iPhone
Best Regards

Asger Jensen
Head of Production
Mail: akj at tmnet.dk<mailto:akj at tmnet.dk>
Mobile: +45 2630 6502


TM
 Niels Hemmingsens Gade 9
 1153 Copenhagen, Denmark
 +45 3344 8555
 www.tmnet.dk<http://www.tmnet.dk>


_______________________________________________
This mail is sent to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please visit
http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev



This e-mail and any files transmitted with it are for the sole use of the intended recipient(s) and may contain confidential and privileged information. If you are not the intended recipient(s), please reply to the sender and destroy all copies of the original message. Any unauthorized review, use, disclosure, dissemination, forwarding, printing or copying of this email, and/or any action taken in reliance on the contents of this e-mail is strictly prohibited and may be unlawful. Where permitted by applicable law, this e-mail and other e-mail communications sent to and from Cognizant e-mail addresses may be monitored.



More information about the opencms-dev mailing list