Metadata-Version: 2.1
Name: redisolar-sample-data-generator
Version: 1.0.5
Summary: A sample data generator for Redis University's example application.
Home-page: https://github.com/redislabs-training/redisolar-sample-data-generator/
Author: Andrew Brookins
Author-email: andrew.brookins@redislabs.com
License: UNKNOWN
Platform: UNKNOWN
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.7
Description-Content-Type: text/markdown
Requires-Dist: redis (==3.5.0)
Requires-Dist: progress (==1.5)
Requires-Dist: mypy (==0.761)
Requires-Dist: hiredis (==1.0.1)
Requires-Dist: click (==7.1.1)
Requires-Dist: marshmallow-dataclass[enum,union] (==7.3.0)
Provides-Extra: dev
Requires-Dist: reorder-python-imports (==1.9.0) ; extra == 'dev'
Requires-Dist: yapf (==0.29.0) ; extra == 'dev'
Requires-Dist: pylint (==2.4.4) ; extra == 'dev'
Requires-Dist: pytest (==5.4.1) ; extra == 'dev'
Requires-Dist: twine (==3.1.1) ; extra == 'dev'

# Redisolar Sample Data Generator

This is a fast sample data generator for the Education team's
"redisolar" applications.


## Python Version

This package requires Python 3.7.


## Installation

After checking out the repository, make sure you are using a virtualenv.
Create one in the checkout directory like this:

    python3 -m venv env


Then activate it:

    source env/bin/activate

Next you can install the Python dependencies with pip:

    pip install .

If you're going to work on the code, install it in "editable" mode
and include the dev dependencies:

    pip install -e ".[dev]"

## Running

This package installs the `load_redisolar` command. Running it generates
sample data and uploads it to a target Redis instance.

By default, `redisolar` uploads to a Redis instance running on localhost at
port 6379, with no password. It uses an included JSON fixture file containing
Site data.

You can override the hostname, port, and fixture file with the `--hostname`,
`--port`, and `--filename` options:

    $ load_redisolar --hostname 192.168.1.2 --port 16379 --filename path/to/sites.json

### Specifying a password

For password-protected Redis instances, you can specify a password
interactively with the `--request-password` option.

    $ load_redisolar --request-password
    Redis password: xyz

Specify a password non-interactively by setting the environment variable
`REDISOLAR_REDIS_PASSWORD`.

    $ export REDISOLAR_REDIS_PASSWORD=xyz
    $ load_redisolar


