pl-simpledsapp
Abstract
simpledsapp is a simple DS plugin that copies directories file from an input to output. If called with an optional --ignoreInputDir the plugin will simply write a JSON formatted timestamp to the output directory.
Synopsis
python simpledsapp.py \
[-v <level>] [--verbosity <level>] \
[--prefix <filePrefixString>] \
[--sleepLength <sleepLength>] \
[--ignoreInputDir] \
[--version] \
[--man] \
[--meta] \
<inputDir>
<outputDir>
Run
This plugin can be run in two modes: natively as a python package or as a containerized docker image.
Using PyPI
To run from PyPI, simply do a
pip install simpledsapp
and run with
simpledsapp.py --man /tmp /tmp
to get inline help. To copy from one directory to another, simply do
simpledsapp.py /some/input/directory /destination/directory
Using docker run
To run using docker, be sure to assign an “input” directory to /incoming and an output directory to /outgoing. Make sure that the $(pwd)/out directory is world writable!
Now, prefix all calls with
docker run --rm -v $(pwd)/out:/outgoing \
fnndsc/pl-simpledsapp simpledsapp.py \
Thus, getting inline help is:
mkdir in out && chmod 777 out
docker run --rm -v $(pwd)/in:/incoming -v $(pwd)/out:/outgoing \
fnndsc/pl-simpledsapp simpledsapp.py \
--man \
/incoming /outgoing
Examples
Copy from input to output with a prefix
Assign an “input” directory to /incoming and an output directory to /outgoing
mkdir in out && chmod 777 out
docker run -v $(pwd)/in:/incoming -v $(pwd)/out:/outgoing \
fnndsc/pl-simpledsapp simpledsapp.py \
--prefix test- \
--sleepLength 0 \
/incoming /outgoing
The above will create a copy of each file in the container’s /incoming and prefix the file copied with the prefix text (in this case “test-“). The copies will be stored in the container’s /outgoing directory.
Simply write a timestamp to the output directory, ignoring the input completely
Assign an “input” directory to /incoming and an output directory to /outgoing
mkdir in out && chmod 777 out
docker run -v $(pwd)/in:/incoming -v $(pwd)/out:/outgoing \
fnndsc/pl-simpledsapp simpledsapp.py \
--ignoreInputDir \
/incoming /outgoing
This will simply create a file called timestamp.json in the output directory. This mode is useful to just create mock nodes in a Feed tree.
Metadata
Release files for simpledsapp 1.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| simpledsapp-1.0.3.tar.gz | 5.0 kB | Without provenance | Details |
Release files / simpledsapp-1.0.3.tar.gz
| Download URL | simpledsapp-1.0.3.tar.gz |
|---|---|
| Size | 5.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9a7a2245113c00ea8cff8a65e57e7bb7f452e51b25c43fe25f0201d6089ed7f4
|
|
BLAKE2b-256 checksum How to use checksums |
b88bcdc8d01566e262ae15df0f76640d446fb2c1321b0c6e8309b2c9f72c4b66
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.5
|
Security for simpledsapp 1.0.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.