A custom Poetry command for IVCAP deployments
Project description
poetry-plugin-ivcap
A custom Poetry plugin that adds a poetry ivcap command for local and Docker-based deployments.
Example Configuration
Add to your pyproject.toml:
[tool.poetry-plugin-ivcap]
service-file = "service.py"
service-id = "urn:ivcap:service:ac158a1f-dfb4-5dac-bf2e-9bf15e0f2cc7"
port = 8077
# docker
# docker-run-opts = { port = 8079 }```
## Installation
```bash
poetry self add poetry-plugin-ivcap
Usage
poetry ivcap run
poetry ivcap docker-build
poetry ivcap docker-run
poetry ivcap docker-publish
poetry ivcap service-register
poetry ivcap create-service-idget
poetry ivcap tool-register
To get help on the currently installed version
% poetry ivcap
IVCAP plugin
Supporting the development of services and tools for the IVCAP platform
Available subcommands:
run Run the service locally
docker-build Build the docker image for this service
docker-run Run the service's docker image locally
docker-publish Publish the service's docker image to IVCAP
service-register Register the service with IVCAP
create-service-id Create a unique service ID for the service
tool-register Register the service as an AI Tool with IVCAP
Example:
poetry ivcap run
Configurable optiosn in pyproject.toml:
[tool.poetry-plugin-ivcap]
service-file = "service.py" # The Python file that implements the service
service-file = "service.py"
service-id = "urn:ivcap:service:ac158a1f-dfb4-5dac-bf2e-9bf15e0f2cc7" # A unique identifier for the service
docker-build-template = "docker buildx build -t #DOCKER_NAME# ."
docker-run-template = "docker run -rm -p #PORT#:#PORT#"
Development
Build the Plugin Package
poetry build
This creates .whl and .tar.gz files in the dist/ directory.
Publish to PyPI
Create an account at https://pypi.org/account/register/
Add your credentials:
poetry config pypi-token.pypi <your-token>
Publish:
poetry publish --build
Optional: Test on TestPyPI First
To verify your setup without publishing to the real PyPI:
poetry config repositories.test-pypi https://test.pypi.org/legacy/
poetry publish -r test-pypi --build
Then test installing via:
poetry self add --source test-pypi poetry-plugin-deploy
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file poetry_plugin_ivcap-0.4.2.tar.gz.
File metadata
- Download URL: poetry_plugin_ivcap-0.4.2.tar.gz
- Upload date:
- Size: 10.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.3 CPython/3.10.10 Darwin/24.5.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4ef9d16395e8ab933cd65717bca3fa429f11ef09ce4181f91515be25e3ed2244
|
|
| MD5 |
2e98e4d1bb058eb07f6bdc64e8258bbf
|
|
| BLAKE2b-256 |
dadb38605e72d3dac5b965897793ac20d625557104a53c36a1f7f9b0129f5671
|
File details
Details for the file poetry_plugin_ivcap-0.4.2-py3-none-any.whl.
File metadata
- Download URL: poetry_plugin_ivcap-0.4.2-py3-none-any.whl
- Upload date:
- Size: 13.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.1.3 CPython/3.10.10 Darwin/24.5.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e6a1a2fc8bf52b3d6bc211369b8534a6cb4481f95208484a9f0c8ba3719c0df5
|
|
| MD5 |
76cef56d2633f741d090e9d2d0dbf9a1
|
|
| BLAKE2b-256 |
b0c7e8647abea1229f1c3c04653c640430f2e3b920775336cebf50ea67f2ce81
|