Are there examples showing how to import an exported (.zip) workspace?

Is there an example showing how to use one of the Nuxeo Shell's automation commands to import an exported (.zip) workspace?

I used the DM/DAM webapp to “export” a workspace and now I would like to use the Nuxeo Shell to import the .zip into another/different workspace.

I named the export file “exported.zip” and put it into the directory on my local workstation from which I launch the Nuxeo Shell client.

Here is what I've tried to no avail:

  1. Started the Nuxeo Shell and connected to my Nuxeo remote DM instance.
  2. Verified that I'm connected by using a remote ls command.
  3. Using local commands, cd'ed to dir containing the exported workspace's .zip file named “exported.zip”
  4. Using remote commands, navigated to a new empty workspace directory
  5. Switched to “automation” namespace
  6. Ran the following FileManager.Import command:
    FileManager.Import exported.zip
    

The operation fails with the following message:

java.lang.RuntimeException: Cannot execute {Authorization=Basic QWRtaW5pc3RyYXRvcjpBZG1pbmlzdHJhdG9y, Content-Type=multipart/related;

boundary="----=_Part_5_380224087.1377035560517", Accept=application/json+nxentity, */*}

Can you point me to or provide me work example of how I can do a successful import from the Nuxeo Shell?

1 votes

0 answers

773 views

ANSWER