deploymentutils
This repo contains a small python package to facilitate deployment of some personal projects.
Overview
This package provides a thin layer on top of fabric to execute commands with a state like
- current working directory
- activated virtual environment (not yet implemented)
It also tries to simplify to deploy/maintain multiple instances of the same software but with varying fixtures, including one or more local instances for testing.
Motivation
The package is mainly intended to facilitate deployment tasks (e.g. for django apps) by running a simple python script. Compared to configuration management tools like Ansible this approach is far less powerful and scalable. However, it might be easier to understand for developers and thus lowering the hurdle to deploy applications by them selves.
Assumed Directory Layout
The scripts marked with [*] make use of this module.
<general project dir>
│
│
├── project-src-repo/ ← official project repo
│ ├── .git/
│ ├── deployment/
│ │ ├── some_files/
│ │ ├── deploy.py [*] ← original deployment script (delivered by the project)
│ │ └── ...
│ ├── django_project/
│ │ ├── settings.py
│ │ └── ...
│ ├── django_app/
│ │ ├── views.py
│ │ └── ...
│ ├── manage.py
│ └── ...
│
├── instance-specific/
│ ├── README.md
│ ├── demo
│ │ ├── .git/
│ │ ├── deploy.py
│ │ ├── project_data
│ │ └── ...
│ ├── production
│ │ ├── .git/
│ │ ├── deploy.py [*]
│ │ ├── project_data
│ │ └── ...
│ ├── testing
│ │ ├── .git/
│ │ ├── deploy.py [*]
│ │ ├── project_data
│ │ └── ...
│ └── ...
│
├── local_testing/ ← contents of this directory are autogenerated
│ ├── deploy.py [*]
│ ├── <appname>_deployment
│ └── ...
.
Status
Still under development and not comprehensively tested.
Features
- Create
config-example.inifrom an existingconfig-production.ini(which contains additional example values).python -c "import deploymentutils as du; print(du.remove_secrets_from_config('config-production.ini'))"- See
test/test_config.iniand unittests for details.
Known Issues
- If a command started by
c.run("some_command")is reading input, then the calling python process waits 'forever', i.e. until interrupted manually.
Metadata
Release files for deploymentutils 0.12.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| deploymentutils-0.12.2.tar.gz | 40.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| deploymentutils-0.12.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 72.3 kB
Release files / deploymentutils-0.12.2.tar.gz
| Download URL | deploymentutils-0.12.2.tar.gz |
|---|---|
| Size | 40.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
79db36b9ce2b1143f37e4e68ffa40c9e42ef24842468e9033b93b90bc8e020ef
|
|
BLAKE2b-256 checksum How to use checksums |
d1b82772b54e5e299f28e8c26e53efed91cda0442d1e8a306643ee1c111e7d74
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.4
|
Release files / deploymentutils-0.12.2-py3-none-any.whl
| Download URL | deploymentutils-0.12.2-py3-none-any.whl |
|---|---|
| Size | 31.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7e67c768c1397031f0a6e08d01ee6dbf6752e62d701ce65268e08245d29386e5
|
|
BLAKE2b-256 checksum How to use checksums |
3f03a0d614e073e663418641fccabb7d38ae35432eb5591a769f7bbae614b65f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.4
|