docker-compose up
docker-compose exec nifi bash
cd /home/nifi
# default nifi docker image doesn't have registry settings, let's add those
cp .nifi-cli.nifi.properties .nifi-cli.registry.properties
# 'nifi' and 'registry' are service hostnames in the docker-compose image
sed -i s/nifi:8080/registry:18080/g .nifi-cli.registry.properties
# tell CLI where our properties file is so we don't have to type them every time
cd /opt/nifi/nifi-toolkit-current/bin
./cli.sh session set nifi.reg.props /home/nifi/.nifi-cli.registry.properties
# link nifi & registry in 1 line (because who needs a UI with a dozen clicks?)
./cli.sh nifi create-reg-client --registryClientName "Local Registry" --registryClientUrl http://registry:18080
./cli.sh demo quick-import --input file:///tmp/flow_tx_enrichment.json
TIP: --input can be any URL, e.g. use https:// and a full path to raw flowfile json on github
https://raw.githubusercontent.com/aperepel/nifi-workshop-2019/master/workshop-flow.json
docker exec -it --user root nifi bash
docker cp ./local-file.txt nifi:/tmp
docker cp nifi:/tmp/remote-file.txt ./local-file.txt