Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

NodeJS - Admin Example - Import Export Documents

A sample admin NodeJS script that import and export documents with Juno.

Getting started

Note

Make sure you have Juno's CLI (npm i -g @junobuild/cli) installed on your machine.

git clone https://github.com/junobuild/examples
cd examples/node/admin/import-export-docs
npm ci

Configuration

Configure the required variables in .env file.

  • DATA_SRC: the path to the JSON data that will be read or written
  • JUNO_DATASTORE_COLLECTION: the datastore's collection in which the data should be read and write

Adapt your Satellite IDs in the juno.config.mjs.

Execution

juno run --src export.mjs
juno run --src import.mjs