- Document Overview
- SECTION 1. Prerequisites
- SECTION 2. Env Prep & Build
- SECTION 3. Promote to TESTPYPI and Test
- SECTION 4. Tag the release
- SECTION 5. Promote to PYPI
Instructions to release py-fortress package
Minimum hardware requirements:
- 1 Core
- 1 GB RAM
Prerequisites:
- Accounts setup on testpypi and pypi with access to py-fortress project
- Account setup on github with contributor access to py-fortress
- python-ldap dependencies installed README-UPGRADE-PYTHON
- Clone the project
git clone https://github.com/shawnmckinney/py-fortress.git
- Change directory into root folder of project:
cd py-fortress
- Prepare the virutal env:
python3 -m venv env
. env/bin/activate
python3 -m pip install --upgrade build
- Build:
python3 -m build
- Setup twine:
pip install --upgrade twine
- Push the package to testpypi:
python3 -m twine upload --repository testpypi dist/*
- Install to test machine
pip3 install -i https://test.pypi.org/simple/ py-fortress --no-deps
- where YOUR-USERNAME-HERE is for account setup on TestPyPI
- Run the tests:
cd sometestfolder
python3 -m venv env
. env/bin/activate
export PYTHONPATH=$(pwd)
pip install "python-ldap>=3.4.2"
pip install "six>=1.16.0"
pip install "ldappool>=3.0.0"
pip3 install -i https://test.pypi.org/simple/ py-fortress --no-deps
export PYFORTRESS_CONF=[path to file]
# run some CLI commands:
cli user add --uid 'chorowitz' --password 'secret' --description 'added with py-fortress cli'
cli user search --uid chorowitz
cli user search --uid p
# etc...
- From the project folder:
git tag -a x.x.x -m "version x.x.x"
git push origin x.x.x
- x.x.x is the release number
- From the project folder
python3 -m pip install --upgrade twine
- Upload to pypy:
python3 -m twine upload dist/*