testando a short description
REPLACE: Add here the list of requirements. For example:
- Python 2.7
- Numpy 1.11.0 or higher
Use the Marvin toolbox to provision, deploy and start the remote HTTP server.
First, edit the marvin.ini
file, setting the options within the
ssh_deployment
section:
host
: the host IP address or name where the engine should be deployed. You can enable multi-host deployment using,
to separate hostsport
: the SSH connection portuser
: the SSH connection username. Currently, only a single user is supported. This user should be capable of passwordless sudo, although it can use password for the SSH connection
Next, ensure that the remotes servers are provisioned (all required software are installed):
marvin engine-deploy --provision
Next, package your engine:
marvin engine-deploy --package
This will create a compressed archive containing your engine code under the
.packages
directory.
Next, deploy your engine to remotes servers:
marvin engine-deploy
By default, a dependency clean will be executed at each deploy. You can skip it using:
marvin engine-deploy --skip-clean
Next, you can start the HTTP server in the remotes servers:
marvin engine-httpserver-remote start
You can check if the HTTP server is running:
marvin engine-httpserver-remote status
And stop it:
marvin engine-httpserver-remote stop
After starting, you can test it by making a HTTP request to any endpoint, like:
curl -v http://example.com/predictor/health
Under the hood, this engine uses Fabric to define provisioning and deployment
process. Check the fabfile.py
for more information. You can add new tasks or
edit existing ones to match your provisioning and deployment pipeline.
First, create a new virtualenv
mkvirtualenv marvin_iris_teste_1_engine_env
Now install the development dependencies
make marvin
You are now ready to code.
It`s very important. All development dependencies should be added to setup.py
.
This project uses py.test as test runner and Tox to manage virtualenvs.
To run all tests use the following command
marvin test
To run specific test
marvin test tests/test_file.py::TestClass::test_method
The project documentation is written using Jupyter notebooks. You can start the notebook server from the command line by running the following command
marvin notebook
Use notebooks to demonstrate how to use the lib features. It can also be useful to show some use cases.
marvin pkg-bumpversion [patch|minor|major]
git add . && git commit -m "Bump version"
marvin pkg-createtag
git push origin master --follow-tags
The default log level is set to WARNING. You can change the log level at runtime setting another value to one of the following environment variable: MARVIN_IRIS_TESTE_1_ENGINE_LOG_LEVEL
or LOG_LEVEL
. The available values are CRITICAL, ERROR, WARNING, INFO and DEBUG.
Be careful using LOG_LEVEL
, it may affect another lib.