diff --git a/.bumpversion.cfg b/.bumpversion.cfg
deleted file mode 100644
index 80fe292..0000000
--- a/.bumpversion.cfg
+++ /dev/null
@@ -1,8 +0,0 @@
-[bumpversion]
-current_version = 0.19.0
-commit = True
-tag = True
-
-[bumpversion:file:setup.py]
-
-[bumpversion:file:dockerized/version.py]
diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json
new file mode 100644
index 0000000..81b33b4
--- /dev/null
+++ b/.devcontainer/devcontainer.json
@@ -0,0 +1,6 @@
+{
+ "image": "mcr.microsoft.com/devcontainers/universal:2",
+ "features": {
+ "ghcr.io/devcontainers-contrib/features/poetry:2": {}
+ }
+}
\ No newline at end of file
diff --git a/.github/workflows/pythonpackage.yml b/.github/workflows/pythonpackage.yml
index 25dc849..c4e4f36 100644
--- a/.github/workflows/pythonpackage.yml
+++ b/.github/workflows/pythonpackage.yml
@@ -12,56 +12,52 @@ jobs:
matrix:
python-version: [3.11]
steps:
- - uses: actions/checkout@v2
+ - uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
- uses: actions/setup-python@v1
+ uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
- python -m pip install --upgrade pip
- pip install pipenv
- pipenv sync --dev
+ pipx install poetry
+ make setup
- name: Test
run: |
- pipenv run invoke test
+ make test
dist:
needs: [build]
if: startsWith(github.ref, 'refs/heads/master')
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
+ - uses: actions/checkout@v4
- name: Set up Python 3.11
- uses: actions/setup-python@v1
+ uses: actions/setup-python@v5
with:
python-version: 3.11
- name: Install dependencies
run: |
- python -m pip install --upgrade pip
- pip install pipenv
- pipenv sync --dev
+ pipx install poetry
+ make setup
- name: Prepare distribution
run: |
- pipenv run invoke dist
+ make dist
- name: Publish (test PyPi)
env:
- TWINE_USERNAME: __token__
- TWINE_PASSWORD: ${{ secrets.test_pypi_apikey }}
+ POETRY_HTTP_BASIC_FOO_USERNAME: __token__
+ POETRY_HTTP_BASIC_FOO_PASSWORD: ${{ secrets.test_pypi_apikey }}
run: |
- pip install twine
- python -m twine upload --repository-url https://test.pypi.org/legacy/ dist/*
+ make publish.testpypi
- name: Install (test PyPi)
run: |
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple dockerized
dockerized version
- name: Publish (PyPi)
env:
- TWINE_USERNAME: __token__
- TWINE_PASSWORD: ${{ secrets.pypi_apikey }}
+ POETRY_HTTP_BASIC_FOO_USERNAME: __token__
+ POETRY_HTTP_BASIC_FOO_PASSWORD: ${{ secrets.pypi_apikey }}
run: |
- pip install twine
- python -m twine upload dist/*
+ make publish
- name: Install (PyPi)
run: |
pip install dockerized
diff --git a/.idea/$CACHE_FILE$ b/.idea/$CACHE_FILE$
deleted file mode 100644
index 6cb8985..0000000
--- a/.idea/$CACHE_FILE$
+++ /dev/null
@@ -1,6 +0,0 @@
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/$PRODUCT_WORKSPACE_FILE$ b/.idea/$PRODUCT_WORKSPACE_FILE$
deleted file mode 100644
index e5626fd..0000000
--- a/.idea/$PRODUCT_WORKSPACE_FILE$
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
-
-
-
-
- Python 3.7
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/.gitignore b/.idea/.gitignore
deleted file mode 100644
index 5c98b42..0000000
--- a/.idea/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-# Default ignored files
-/workspace.xml
\ No newline at end of file
diff --git a/.idea/misc.xml b/.idea/misc.xml
deleted file mode 100644
index cdaff91..0000000
--- a/.idea/misc.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/modules.xml b/.idea/modules.xml
deleted file mode 100644
index c3c11c2..0000000
--- a/.idea/modules.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/vcs.xml b/.idea/vcs.xml
deleted file mode 100644
index 35eb1dd..0000000
--- a/.idea/vcs.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-
-
-
-
-
-
\ No newline at end of file
diff --git a/Makefile b/Makefile
index 2751c4c..1aa192d 100644
--- a/Makefile
+++ b/Makefile
@@ -1,20 +1,35 @@
default:
:
+.PHONY: setup
setup:
- pipenv sync --dev
+ poetry install --no-root
+.PHONY: test
test:
- pipenv run invoke test
+ poetry run python -m unittest -v
+.PHONY: dist
dist:
- pipenv run invoke dist
+ poetry build
+
+.PHONY: publish.testpypi
+publish.testpypi:
+ poetry config repositories.testpypi https://test.pypi.org/legacy/
+ poetry publish --repository testpypi
+
+.PHONY: publish
+publish:
+ poetry publish
bumpversion.major:
- pipenv run invoke bumpversion major
+ poetry version major
+ echo "VERSION = '$$(poetry version -s)'" > dockerized/version.py
bumpversion.minor:
- pipenv run invoke bumpversion minor
+ poetry version minor
+ echo "VERSION = '$$(poetry version -s)'" > dockerized/version.py
bumpversion.patch:
- pipenv run invoke bumpversion patch
+ poetry version patch
+ echo "VERSION = '$$(poetry version -s)'" > dockerized/version.py
diff --git a/Pipfile b/Pipfile
deleted file mode 100644
index b3c975e..0000000
--- a/Pipfile
+++ /dev/null
@@ -1,18 +0,0 @@
-[[source]]
-name = "pypi"
-url = "https://pypi.org/simple"
-verify_ssl = true
-
-[dev-packages]
-invoke = "==2.2.0"
-setuptools = "==69.1.1"
-wheel = "==0.42.0"
-bumpversion = "==0.6.0"
-pipenv-setup = "==3.2.0"
-
-[packages]
-click = "==7.1.2"
-pyyaml = "==6.0.1"
-
-[requires]
-python_version = "3.11"
diff --git a/Pipfile.lock b/Pipfile.lock
deleted file mode 100644
index 4f8ade4..0000000
--- a/Pipfile.lock
+++ /dev/null
@@ -1,442 +0,0 @@
-{
- "_meta": {
- "hash": {
- "sha256": "e06df2441f57195f622cdfa0d63d86795036c96078952cce7f31ace2938c3a40"
- },
- "pipfile-spec": 6,
- "requires": {
- "python_version": "3.11"
- },
- "sources": [
- {
- "name": "pypi",
- "url": "https://pypi.org/simple",
- "verify_ssl": true
- }
- ]
- },
- "default": {
- "click": {
- "hashes": [
- "sha256:d2b5255c7c6349bc1bd1e59e08cd12acbbd63ce649f2588755783aa94dfb6b1a",
- "sha256:dacca89f4bfadd5de3d7489b7c8a566eee0d3676333fbb50030263894c38c0dc"
- ],
- "index": "pypi",
- "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4'",
- "version": "==7.1.2"
- },
- "pyyaml": {
- "hashes": [
- "sha256:04ac92ad1925b2cff1db0cfebffb6ffc43457495c9b3c39d3fcae417d7125dc5",
- "sha256:062582fca9fabdd2c8b54a3ef1c978d786e0f6b3a1510e0ac93ef59e0ddae2bc",
- "sha256:0d3304d8c0adc42be59c5f8a4d9e3d7379e6955ad754aa9d6ab7a398b59dd1df",
- "sha256:1635fd110e8d85d55237ab316b5b011de701ea0f29d07611174a1b42f1444741",
- "sha256:184c5108a2aca3c5b3d3bf9395d50893a7ab82a38004c8f61c258d4428e80206",
- "sha256:18aeb1bf9a78867dc38b259769503436b7c72f7a1f1f4c93ff9a17de54319b27",
- "sha256:1d4c7e777c441b20e32f52bd377e0c409713e8bb1386e1099c2415f26e479595",
- "sha256:1e2722cc9fbb45d9b87631ac70924c11d3a401b2d7f410cc0e3bbf249f2dca62",
- "sha256:1fe35611261b29bd1de0070f0b2f47cb6ff71fa6595c077e42bd0c419fa27b98",
- "sha256:28c119d996beec18c05208a8bd78cbe4007878c6dd15091efb73a30e90539696",
- "sha256:326c013efe8048858a6d312ddd31d56e468118ad4cdeda36c719bf5bb6192290",
- "sha256:40df9b996c2b73138957fe23a16a4f0ba614f4c0efce1e9406a184b6d07fa3a9",
- "sha256:42f8152b8dbc4fe7d96729ec2b99c7097d656dc1213a3229ca5383f973a5ed6d",
- "sha256:49a183be227561de579b4a36efbb21b3eab9651dd81b1858589f796549873dd6",
- "sha256:4fb147e7a67ef577a588a0e2c17b6db51dda102c71de36f8549b6816a96e1867",
- "sha256:50550eb667afee136e9a77d6dc71ae76a44df8b3e51e41b77f6de2932bfe0f47",
- "sha256:510c9deebc5c0225e8c96813043e62b680ba2f9c50a08d3724c7f28a747d1486",
- "sha256:5773183b6446b2c99bb77e77595dd486303b4faab2b086e7b17bc6bef28865f6",
- "sha256:596106435fa6ad000c2991a98fa58eeb8656ef2325d7e158344fb33864ed87e3",
- "sha256:6965a7bc3cf88e5a1c3bd2e0b5c22f8d677dc88a455344035f03399034eb3007",
- "sha256:69b023b2b4daa7548bcfbd4aa3da05b3a74b772db9e23b982788168117739938",
- "sha256:6c22bec3fbe2524cde73d7ada88f6566758a8f7227bfbf93a408a9d86bcc12a0",
- "sha256:704219a11b772aea0d8ecd7058d0082713c3562b4e271b849ad7dc4a5c90c13c",
- "sha256:7e07cbde391ba96ab58e532ff4803f79c4129397514e1413a7dc761ccd755735",
- "sha256:81e0b275a9ecc9c0c0c07b4b90ba548307583c125f54d5b6946cfee6360c733d",
- "sha256:855fb52b0dc35af121542a76b9a84f8d1cd886ea97c84703eaa6d88e37a2ad28",
- "sha256:8d4e9c88387b0f5c7d5f281e55304de64cf7f9c0021a3525bd3b1c542da3b0e4",
- "sha256:9046c58c4395dff28dd494285c82ba00b546adfc7ef001486fbf0324bc174fba",
- "sha256:9eb6caa9a297fc2c2fb8862bc5370d0303ddba53ba97e71f08023b6cd73d16a8",
- "sha256:a08c6f0fe150303c1c6b71ebcd7213c2858041a7e01975da3a99aed1e7a378ef",
- "sha256:a0cd17c15d3bb3fa06978b4e8958dcdc6e0174ccea823003a106c7d4d7899ac5",
- "sha256:afd7e57eddb1a54f0f1a974bc4391af8bcce0b444685d936840f125cf046d5bd",
- "sha256:b1275ad35a5d18c62a7220633c913e1b42d44b46ee12554e5fd39c70a243d6a3",
- "sha256:b786eecbdf8499b9ca1d697215862083bd6d2a99965554781d0d8d1ad31e13a0",
- "sha256:ba336e390cd8e4d1739f42dfe9bb83a3cc2e80f567d8805e11b46f4a943f5515",
- "sha256:baa90d3f661d43131ca170712d903e6295d1f7a0f595074f151c0aed377c9b9c",
- "sha256:bc1bf2925a1ecd43da378f4db9e4f799775d6367bdb94671027b73b393a7c42c",
- "sha256:bd4af7373a854424dabd882decdc5579653d7868b8fb26dc7d0e99f823aa5924",
- "sha256:bf07ee2fef7014951eeb99f56f39c9bb4af143d8aa3c21b1677805985307da34",
- "sha256:bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43",
- "sha256:c8098ddcc2a85b61647b2590f825f3db38891662cfc2fc776415143f599bb859",
- "sha256:d2b04aac4d386b172d5b9692e2d2da8de7bfb6c387fa4f801fbf6fb2e6ba4673",
- "sha256:d483d2cdf104e7c9fa60c544d92981f12ad66a457afae824d146093b8c294c54",
- "sha256:d858aa552c999bc8a8d57426ed01e40bef403cd8ccdd0fc5f6f04a00414cac2a",
- "sha256:e7d73685e87afe9f3b36c799222440d6cf362062f78be1013661b00c5c6f678b",
- "sha256:f003ed9ad21d6a4713f0a9b5a7a0a79e08dd0f221aff4525a2be4c346ee60aab",
- "sha256:f22ac1c3cac4dbc50079e965eba2c1058622631e526bd9afd45fedd49ba781fa",
- "sha256:faca3bdcf85b2fc05d06ff3fbc1f83e1391b3e724afa3feba7d13eeab355484c",
- "sha256:fca0e3a251908a499833aa292323f32437106001d436eca0e6e7833256674585",
- "sha256:fd1592b3fdf65fff2ad0004b5e363300ef59ced41c2e6b3a99d4089fa8c5435d",
- "sha256:fd66fc5d0da6d9815ba2cebeb4205f95818ff4b79c3ebe268e75d961704af52f"
- ],
- "index": "pypi",
- "markers": "python_version >= '3.6'",
- "version": "==6.0.1"
- }
- },
- "develop": {
- "attrs": {
- "hashes": [
- "sha256:935dc3b529c262f6cf76e50877d35a4bd3c1de194fd41f47a2b7ae8f19971f30",
- "sha256:99b87a485a5820b23b879f04c2305b44b951b502fd64be915879d77a7e8fc6f1"
- ],
- "markers": "python_version >= '3.7'",
- "version": "==23.2.0"
- },
- "bump2version": {
- "hashes": [
- "sha256:37f927ea17cde7ae2d7baf832f8e80ce3777624554a653006c9144f8017fe410",
- "sha256:762cb2bfad61f4ec8e2bdf452c7c267416f8c70dd9ecb1653fd0bbb01fa936e6"
- ],
- "markers": "python_version >= '3.5'",
- "version": "==1.0.1"
- },
- "bumpversion": {
- "hashes": [
- "sha256:4ba55e4080d373f80177b4dabef146c07ce73c7d1377aabf9d3c3ae1f94584a6",
- "sha256:4eb3267a38194d09f048a2179980bb4803701969bff2c85fa8f6d1ce050be15e"
- ],
- "index": "pypi",
- "version": "==0.6.0"
- },
- "cached-property": {
- "hashes": [
- "sha256:9fa5755838eecbb2d234c3aa390bd80fbd3ac6b6869109bfc1b499f7bd89a130",
- "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"
- ],
- "version": "==1.5.2"
- },
- "cerberus": {
- "hashes": [
- "sha256:7649a5815024d18eb7c6aa5e7a95355c649a53aacfc9b050e9d0bf6bfa2af372",
- "sha256:81011e10266ef71b6ec6d50e60171258a5b134d69f8fb387d16e4936d0d47642"
- ],
- "version": "==1.3.5"
- },
- "certifi": {
- "hashes": [
- "sha256:0569859f95fc761b18b45ef421b1290a0f65f147e92a1e5eb3e635f9a5e4e66f",
- "sha256:dc383c07b76109f368f6106eee2b593b04a011ea4d55f652c6ca24a754d1cdd1"
- ],
- "markers": "python_version >= '3.6'",
- "version": "==2024.2.2"
- },
- "chardet": {
- "hashes": [
- "sha256:0368df2bfd78b5fc20572bb4e9bb7fb53e2c094f60ae9993339e8671d0afb8aa",
- "sha256:d3e64f022d254183001eccc5db4040520c0f23b1a3f33d6413e099eb7f126557"
- ],
- "markers": "python_version >= '3.6'",
- "version": "==5.0.0"
- },
- "charset-normalizer": {
- "hashes": [
- "sha256:06435b539f889b1f6f4ac1758871aae42dc3a8c0e24ac9e60c2384973ad73027",
- "sha256:06a81e93cd441c56a9b65d8e1d043daeb97a3d0856d177d5c90ba85acb3db087",
- "sha256:0a55554a2fa0d408816b3b5cedf0045f4b8e1a6065aec45849de2d6f3f8e9786",
- "sha256:0b2b64d2bb6d3fb9112bafa732def486049e63de9618b5843bcdd081d8144cd8",
- "sha256:10955842570876604d404661fbccbc9c7e684caf432c09c715ec38fbae45ae09",
- "sha256:122c7fa62b130ed55f8f285bfd56d5f4b4a5b503609d181f9ad85e55c89f4185",
- "sha256:1ceae2f17a9c33cb48e3263960dc5fc8005351ee19db217e9b1bb15d28c02574",
- "sha256:1d3193f4a680c64b4b6a9115943538edb896edc190f0b222e73761716519268e",
- "sha256:1f79682fbe303db92bc2b1136016a38a42e835d932bab5b3b1bfcfbf0640e519",
- "sha256:2127566c664442652f024c837091890cb1942c30937add288223dc895793f898",
- "sha256:22afcb9f253dac0696b5a4be4a1c0f8762f8239e21b99680099abd9b2b1b2269",
- "sha256:25baf083bf6f6b341f4121c2f3c548875ee6f5339300e08be3f2b2ba1721cdd3",
- "sha256:2e81c7b9c8979ce92ed306c249d46894776a909505d8f5a4ba55b14206e3222f",
- "sha256:3287761bc4ee9e33561a7e058c72ac0938c4f57fe49a09eae428fd88aafe7bb6",
- "sha256:34d1c8da1e78d2e001f363791c98a272bb734000fcef47a491c1e3b0505657a8",
- "sha256:37e55c8e51c236f95b033f6fb391d7d7970ba5fe7ff453dad675e88cf303377a",
- "sha256:3d47fa203a7bd9c5b6cee4736ee84ca03b8ef23193c0d1ca99b5089f72645c73",
- "sha256:3e4d1f6587322d2788836a99c69062fbb091331ec940e02d12d179c1d53e25fc",
- "sha256:42cb296636fcc8b0644486d15c12376cb9fa75443e00fb25de0b8602e64c1714",
- "sha256:45485e01ff4d3630ec0d9617310448a8702f70e9c01906b0d0118bdf9d124cf2",
- "sha256:4a78b2b446bd7c934f5dcedc588903fb2f5eec172f3d29e52a9096a43722adfc",
- "sha256:4ab2fe47fae9e0f9dee8c04187ce5d09f48eabe611be8259444906793ab7cbce",
- "sha256:4d0d1650369165a14e14e1e47b372cfcb31d6ab44e6e33cb2d4e57265290044d",
- "sha256:549a3a73da901d5bc3ce8d24e0600d1fa85524c10287f6004fbab87672bf3e1e",
- "sha256:55086ee1064215781fff39a1af09518bc9255b50d6333f2e4c74ca09fac6a8f6",
- "sha256:572c3763a264ba47b3cf708a44ce965d98555f618ca42c926a9c1616d8f34269",
- "sha256:573f6eac48f4769d667c4442081b1794f52919e7edada77495aaed9236d13a96",
- "sha256:5b4c145409bef602a690e7cfad0a15a55c13320ff7a3ad7ca59c13bb8ba4d45d",
- "sha256:6463effa3186ea09411d50efc7d85360b38d5f09b870c48e4600f63af490e56a",
- "sha256:65f6f63034100ead094b8744b3b97965785388f308a64cf8d7c34f2f2e5be0c4",
- "sha256:663946639d296df6a2bb2aa51b60a2454ca1cb29835324c640dafb5ff2131a77",
- "sha256:6897af51655e3691ff853668779c7bad41579facacf5fd7253b0133308cf000d",
- "sha256:68d1f8a9e9e37c1223b656399be5d6b448dea850bed7d0f87a8311f1ff3dabb0",
- "sha256:6ac7ffc7ad6d040517be39eb591cac5ff87416c2537df6ba3cba3bae290c0fed",
- "sha256:6b3251890fff30ee142c44144871185dbe13b11bab478a88887a639655be1068",
- "sha256:6c4caeef8fa63d06bd437cd4bdcf3ffefe6738fb1b25951440d80dc7df8c03ac",
- "sha256:6ef1d82a3af9d3eecdba2321dc1b3c238245d890843e040e41e470ffa64c3e25",
- "sha256:753f10e867343b4511128c6ed8c82f7bec3bd026875576dfd88483c5c73b2fd8",
- "sha256:7cd13a2e3ddeed6913a65e66e94b51d80a041145a026c27e6bb76c31a853c6ab",
- "sha256:7ed9e526742851e8d5cc9e6cf41427dfc6068d4f5a3bb03659444b4cabf6bc26",
- "sha256:7f04c839ed0b6b98b1a7501a002144b76c18fb1c1850c8b98d458ac269e26ed2",
- "sha256:802fe99cca7457642125a8a88a084cef28ff0cf9407060f7b93dca5aa25480db",
- "sha256:80402cd6ee291dcb72644d6eac93785fe2c8b9cb30893c1af5b8fdd753b9d40f",
- "sha256:8465322196c8b4d7ab6d1e049e4c5cb460d0394da4a27d23cc242fbf0034b6b5",
- "sha256:86216b5cee4b06df986d214f664305142d9c76df9b6512be2738aa72a2048f99",
- "sha256:87d1351268731db79e0f8e745d92493ee2841c974128ef629dc518b937d9194c",
- "sha256:8bdb58ff7ba23002a4c5808d608e4e6c687175724f54a5dade5fa8c67b604e4d",
- "sha256:8c622a5fe39a48f78944a87d4fb8a53ee07344641b0562c540d840748571b811",
- "sha256:8d756e44e94489e49571086ef83b2bb8ce311e730092d2c34ca8f7d925cb20aa",
- "sha256:8f4a014bc36d3c57402e2977dada34f9c12300af536839dc38c0beab8878f38a",
- "sha256:9063e24fdb1e498ab71cb7419e24622516c4a04476b17a2dab57e8baa30d6e03",
- "sha256:90d558489962fd4918143277a773316e56c72da56ec7aa3dc3dbbe20fdfed15b",
- "sha256:923c0c831b7cfcb071580d3f46c4baf50f174be571576556269530f4bbd79d04",
- "sha256:95f2a5796329323b8f0512e09dbb7a1860c46a39da62ecb2324f116fa8fdc85c",
- "sha256:96b02a3dc4381e5494fad39be677abcb5e6634bf7b4fa83a6dd3112607547001",
- "sha256:9f96df6923e21816da7e0ad3fd47dd8f94b2a5ce594e00677c0013018b813458",
- "sha256:a10af20b82360ab00827f916a6058451b723b4e65030c5a18577c8b2de5b3389",
- "sha256:a50aebfa173e157099939b17f18600f72f84eed3049e743b68ad15bd69b6bf99",
- "sha256:a981a536974bbc7a512cf44ed14938cf01030a99e9b3a06dd59578882f06f985",
- "sha256:a9a8e9031d613fd2009c182b69c7b2c1ef8239a0efb1df3f7c8da66d5dd3d537",
- "sha256:ae5f4161f18c61806f411a13b0310bea87f987c7d2ecdbdaad0e94eb2e404238",
- "sha256:aed38f6e4fb3f5d6bf81bfa990a07806be9d83cf7bacef998ab1a9bd660a581f",
- "sha256:b01b88d45a6fcb69667cd6d2f7a9aeb4bf53760d7fc536bf679ec94fe9f3ff3d",
- "sha256:b261ccdec7821281dade748d088bb6e9b69e6d15b30652b74cbbac25e280b796",
- "sha256:b2b0a0c0517616b6869869f8c581d4eb2dd83a4d79e0ebcb7d373ef9956aeb0a",
- "sha256:b4a23f61ce87adf89be746c8a8974fe1c823c891d8f86eb218bb957c924bb143",
- "sha256:bd8f7df7d12c2db9fab40bdd87a7c09b1530128315d047a086fa3ae3435cb3a8",
- "sha256:beb58fe5cdb101e3a055192ac291b7a21e3b7ef4f67fa1d74e331a7f2124341c",
- "sha256:c002b4ffc0be611f0d9da932eb0f704fe2602a9a949d1f738e4c34c75b0863d5",
- "sha256:c083af607d2515612056a31f0a8d9e0fcb5876b7bfc0abad3ecd275bc4ebc2d5",
- "sha256:c180f51afb394e165eafe4ac2936a14bee3eb10debc9d9e4db8958fe36afe711",
- "sha256:c235ebd9baae02f1b77bcea61bce332cb4331dc3617d254df3323aa01ab47bd4",
- "sha256:cd70574b12bb8a4d2aaa0094515df2463cb429d8536cfb6c7ce983246983e5a6",
- "sha256:d0eccceffcb53201b5bfebb52600a5fb483a20b61da9dbc885f8b103cbe7598c",
- "sha256:d965bba47ddeec8cd560687584e88cf699fd28f192ceb452d1d7ee807c5597b7",
- "sha256:db364eca23f876da6f9e16c9da0df51aa4f104a972735574842618b8c6d999d4",
- "sha256:ddbb2551d7e0102e7252db79ba445cdab71b26640817ab1e3e3648dad515003b",
- "sha256:deb6be0ac38ece9ba87dea880e438f25ca3eddfac8b002a2ec3d9183a454e8ae",
- "sha256:e06ed3eb3218bc64786f7db41917d4e686cc4856944f53d5bdf83a6884432e12",
- "sha256:e27ad930a842b4c5eb8ac0016b0a54f5aebbe679340c26101df33424142c143c",
- "sha256:e537484df0d8f426ce2afb2d0f8e1c3d0b114b83f8850e5f2fbea0e797bd82ae",
- "sha256:eb00ed941194665c332bf8e078baf037d6c35d7c4f3102ea2d4f16ca94a26dc8",
- "sha256:eb6904c354526e758fda7167b33005998fb68c46fbc10e013ca97f21ca5c8887",
- "sha256:eb8821e09e916165e160797a6c17edda0679379a4be5c716c260e836e122f54b",
- "sha256:efcb3f6676480691518c177e3b465bcddf57cea040302f9f4e6e191af91174d4",
- "sha256:f27273b60488abe721a075bcca6d7f3964f9f6f067c8c4c605743023d7d3944f",
- "sha256:f30c3cb33b24454a82faecaf01b19c18562b1e89558fb6c56de4d9118a032fd5",
- "sha256:fb69256e180cb6c8a894fee62b3afebae785babc1ee98b81cdf68bbca1987f33",
- "sha256:fd1abc0d89e30cc4e02e4064dc67fcc51bd941eb395c502aac3ec19fab46b519",
- "sha256:ff8fa367d09b717b2a17a052544193ad76cd49979c805768879cb63d9ca50561"
- ],
- "markers": "python_full_version >= '3.7.0'",
- "version": "==3.3.2"
- },
- "colorama": {
- "hashes": [
- "sha256:08695f5cb7ed6e0531a20572697297273c47b8cae5a63ffc6d6ed5c201be6e44",
- "sha256:4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6"
- ],
- "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6'",
- "version": "==0.4.6"
- },
- "distlib": {
- "hashes": [
- "sha256:034db59a0b96f8ca18035f36290806a9a6e6bd9d1ff91e45a7f172eb17e51784",
- "sha256:1530ea13e350031b6312d8580ddb6b27a104275a31106523b8f123787f494f64"
- ],
- "version": "==0.3.8"
- },
- "idna": {
- "hashes": [
- "sha256:9ecdbbd083b06798ae1e86adcbfe8ab1479cf864e4ee30fe4e46a003d12491ca",
- "sha256:c05567e9c24a6b9faaa835c4821bad0590fbb9d5779e7caa6e1cc4978e7eb24f"
- ],
- "markers": "python_version >= '3.5'",
- "version": "==3.6"
- },
- "invoke": {
- "hashes": [
- "sha256:6ea924cc53d4f78e3d98bc436b08069a03077e6f85ad1ddaa8a116d7dad15820",
- "sha256:ee6cbb101af1a859c7fe84f2a264c059020b0cb7fe3535f9424300ab568f6bd5"
- ],
- "index": "pypi",
- "markers": "python_version >= '3.6'",
- "version": "==2.2.0"
- },
- "orderedmultidict": {
- "hashes": [
- "sha256:04070bbb5e87291cc9bfa51df413677faf2141c73c61d2a5f7b26bea3cd882ad",
- "sha256:43c839a17ee3cdd62234c47deca1a8508a3f2ca1d0678a3bf791c87cf84adbf3"
- ],
- "version": "==1.0.1"
- },
- "packaging": {
- "hashes": [
- "sha256:5b327ac1320dc863dca72f4514ecc086f31186744b84a230374cc1fd776feae5",
- "sha256:67714da7f7bc052e064859c05c595155bd1ee9f69f76557e21f051443c20947a"
- ],
- "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'",
- "version": "==20.9"
- },
- "pep517": {
- "hashes": [
- "sha256:1b2fa2ffd3938bb4beffe5d6146cbcb2bda996a5a4da9f31abffd8b24e07b317",
- "sha256:31b206f67165b3536dd577c5c3f1518e8fbaf38cbc57efff8369a392feff1721"
- ],
- "markers": "python_version >= '3.6'",
- "version": "==0.13.1"
- },
- "pip": {
- "hashes": [
- "sha256:ba0d021a166865d2265246961bec0152ff124de910c5cc39f1156ce3fa7c69dc",
- "sha256:ea9bd1a847e8c5774a5777bb398c19e80bcd4e2aa16a4b301b718fe6f593aba2"
- ],
- "markers": "python_version >= '3.7'",
- "version": "==24.0"
- },
- "pip-shims": {
- "hashes": [
- "sha256:089e3586a92b1b8dbbc16b2d2859331dc1c412d3e3dbcd91d80e6b30d73db96c",
- "sha256:2ae9f21c0155ca5c37d2734eb5f9a7d98c4c42a122d1ba3eddbacc9d9ea9fbae"
- ],
- "markers": "python_version >= '3.6'",
- "version": "==0.7.3"
- },
- "pipenv-setup": {
- "hashes": [
- "sha256:0def7ec3363f58b38a43dc59b2078fcee67b47301fd51a41b8e34e6f79812b1a",
- "sha256:6ceda7145a3088494d8ca68fded4b0473022dc62eb786a021c137632c44298b5"
- ],
- "index": "pypi",
- "markers": "python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3' and python_version < '4'",
- "version": "==3.2.0"
- },
- "pipfile": {
- "hashes": [
- "sha256:f7d9f15de8b660986557eb3cc5391aa1a16207ac41bc378d03f414762d36c984"
- ],
- "version": "==0.0.2"
- },
- "platformdirs": {
- "hashes": [
- "sha256:0614df2a2f37e1a662acbd8e2b25b92ccf8632929bc6d43467e17fe89c75e068",
- "sha256:ef0cc731df711022c174543cb70a9b5bd22e5a9337c8624ef2c2ceb8ddad8768"
- ],
- "markers": "python_version >= '3.8'",
- "version": "==4.2.0"
- },
- "plette": {
- "extras": [
- "validation"
- ],
- "hashes": [
- "sha256:12c51cd69e8e15d0bba9ea6028d9119cf143ebc418a1b6d2e7ae053db05eb768",
- "sha256:a853b7a8f9e106c652a44ad356a88ac06c45036cc6ee01c6ba6165cfd752982c"
- ],
- "markers": "python_version >= '3.7'",
- "version": "==1.0.0"
- },
- "pyparsing": {
- "hashes": [
- "sha256:c203ec8783bf771a155b207279b9bccb8dea02d8f0c9e5f8ead507bc3246ecc1",
- "sha256:ef9d7589ef3c200abe66653d3f1ab1033c3c419ae9b9bdb1240a85b024efc88b"
- ],
- "markers": "python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3'",
- "version": "==2.4.7"
- },
- "python-dateutil": {
- "hashes": [
- "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86",
- "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"
- ],
- "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'",
- "version": "==2.8.2"
- },
- "requests": {
- "hashes": [
- "sha256:58cd2187c01e70e6e26505bca751777aa9f2ee0b7f4300988b709f44e013003f",
- "sha256:942c5a758f98d790eaed1a29cb6eefc7ffb0d1cf7af05c3d2791656dbd6ad1e1"
- ],
- "markers": "python_version >= '3.7'",
- "version": "==2.31.0"
- },
- "requirementslib": {
- "hashes": [
- "sha256:28924cf11a2fa91adb03f8431d80c2a8c3dc386f1c48fb2be9a58e4c39072354",
- "sha256:d26ec6ad45e1ffce9532303543996c9c71a99dc65f783908f112e3f2aae7e49c"
- ],
- "markers": "python_version >= '3.7'",
- "version": "==1.6.9"
- },
- "setuptools": {
- "hashes": [
- "sha256:02fa291a0471b3a18b2b2481ed902af520c69e8ae0919c13da936542754b4c56",
- "sha256:5c0806c7d9af348e6dd3777b4f4dbb42c7ad85b190104837488eab9a7c945cf8"
- ],
- "index": "pypi",
- "markers": "python_version >= '3.8'",
- "version": "==69.1.1"
- },
- "six": {
- "hashes": [
- "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926",
- "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"
- ],
- "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'",
- "version": "==1.16.0"
- },
- "toml": {
- "hashes": [
- "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b",
- "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"
- ],
- "markers": "python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3'",
- "version": "==0.10.2"
- },
- "tomli": {
- "hashes": [
- "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc",
- "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"
- ],
- "markers": "python_version < '3.11'",
- "version": "==2.0.1"
- },
- "tomlkit": {
- "hashes": [
- "sha256:75baf5012d06501f07bee5bf8e801b9f343e7aac5a92581f20f80ce632e6b5a4",
- "sha256:b0a645a9156dc7cb5d3a1f0d4bab66db287fcb8e0430bdd4664a095ea16414ba"
- ],
- "markers": "python_version >= '3.7'",
- "version": "==0.12.3"
- },
- "urllib3": {
- "hashes": [
- "sha256:450b20ec296a467077128bff42b73080516e71b56ff59a60a02bef2232c4fa9d",
- "sha256:d0570876c61ab9e520d776c38acbbb5b05a776d3f9ff98a5c8fd5162a444cf19"
- ],
- "markers": "python_version >= '3.8'",
- "version": "==2.2.1"
- },
- "vistir": {
- "hashes": [
- "sha256:7b8d2301c860707a7a7f02c457eef685b9711470a6df157b692baf529606622f",
- "sha256:dde88ef0d45dc1ad423fff2f0ad0e29e230de1b02457bdff5053dacd60ffcf97"
- ],
- "markers": "python_version >= '3.7'",
- "version": "==0.8.0"
- },
- "wheel": {
- "hashes": [
- "sha256:177f9c9b0d45c47873b619f5b650346d632cdc35fb5e4d25058e09c9e581433d",
- "sha256:c45be39f7882c9d34243236f2d63cbd58039e360f85d0913425fbd7ceea617a8"
- ],
- "index": "pypi",
- "markers": "python_version >= '3.7'",
- "version": "==0.42.0"
- }
- }
-}
diff --git a/bin/.gitignore b/bin/.gitignore
deleted file mode 100644
index f2dde14..0000000
--- a/bin/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-dockerized
diff --git a/dockerized-cli.iml b/dockerized-cli.iml
deleted file mode 100644
index 937ff7e..0000000
--- a/dockerized-cli.iml
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dockerized.py b/dockerized.py
deleted file mode 100755
index b18ccbe..0000000
--- a/dockerized.py
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/usr/bin/env python3
-from dockerized.ui import cli
-
-if __name__ == '__main__':
- cli.main()
diff --git a/dockerized/ui/cli.py b/dockerized/ui/cli.py
index 5c07bc8..46d7fe0 100644
--- a/dockerized/ui/cli.py
+++ b/dockerized/ui/cli.py
@@ -145,4 +145,8 @@ def compose(command):
def version():
version_command = VersionCommand()
version = version_command.run()
- click.echo(version)
\ No newline at end of file
+ click.echo(version)
+
+
+if __name__ == "__main__":
+ main()
diff --git a/dockerized/version.py b/dockerized/version.py
index ca0e645..444ae3a 100644
--- a/dockerized/version.py
+++ b/dockerized/version.py
@@ -1 +1 @@
-VERSION = '0.19.0'
\ No newline at end of file
+VERSION = '0.21.0'
diff --git a/fixtures/with_config/.dockerized/config.yml b/fixtures/with_config/.dockerized/config.yml
index 29ead1f..fc484ed 100644
--- a/fixtures/with_config/.dockerized/config.yml
+++ b/fixtures/with_config/.dockerized/config.yml
@@ -1,4 +1,4 @@
compose_files:
- - ../foo/docker-compose.yml
- ./docker-compose.dockerized.yml
+ - ../foo/docker-compose.yml
service_name: app
\ No newline at end of file
diff --git a/poetry.lock b/poetry.lock
new file mode 100644
index 0000000..38584af
--- /dev/null
+++ b/poetry.lock
@@ -0,0 +1,77 @@
+# This file is automatically @generated by Poetry 1.8.1 and should not be changed by hand.
+
+[[package]]
+name = "click"
+version = "7.1.2"
+description = "Composable command line interface toolkit"
+optional = false
+python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*"
+files = [
+ {file = "click-7.1.2-py2.py3-none-any.whl", hash = "sha256:dacca89f4bfadd5de3d7489b7c8a566eee0d3676333fbb50030263894c38c0dc"},
+ {file = "click-7.1.2.tar.gz", hash = "sha256:d2b5255c7c6349bc1bd1e59e08cd12acbbd63ce649f2588755783aa94dfb6b1a"},
+]
+
+[[package]]
+name = "pyyaml"
+version = "6.0.1"
+description = "YAML parser and emitter for Python"
+optional = false
+python-versions = ">=3.6"
+files = [
+ {file = "PyYAML-6.0.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d858aa552c999bc8a8d57426ed01e40bef403cd8ccdd0fc5f6f04a00414cac2a"},
+ {file = "PyYAML-6.0.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:fd66fc5d0da6d9815ba2cebeb4205f95818ff4b79c3ebe268e75d961704af52f"},
+ {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:69b023b2b4daa7548bcfbd4aa3da05b3a74b772db9e23b982788168117739938"},
+ {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:81e0b275a9ecc9c0c0c07b4b90ba548307583c125f54d5b6946cfee6360c733d"},
+ {file = "PyYAML-6.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ba336e390cd8e4d1739f42dfe9bb83a3cc2e80f567d8805e11b46f4a943f5515"},
+ {file = "PyYAML-6.0.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:326c013efe8048858a6d312ddd31d56e468118ad4cdeda36c719bf5bb6192290"},
+ {file = "PyYAML-6.0.1-cp310-cp310-win32.whl", hash = "sha256:bd4af7373a854424dabd882decdc5579653d7868b8fb26dc7d0e99f823aa5924"},
+ {file = "PyYAML-6.0.1-cp310-cp310-win_amd64.whl", hash = "sha256:fd1592b3fdf65fff2ad0004b5e363300ef59ced41c2e6b3a99d4089fa8c5435d"},
+ {file = "PyYAML-6.0.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:6965a7bc3cf88e5a1c3bd2e0b5c22f8d677dc88a455344035f03399034eb3007"},
+ {file = "PyYAML-6.0.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:f003ed9ad21d6a4713f0a9b5a7a0a79e08dd0f221aff4525a2be4c346ee60aab"},
+ {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:42f8152b8dbc4fe7d96729ec2b99c7097d656dc1213a3229ca5383f973a5ed6d"},
+ {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:062582fca9fabdd2c8b54a3ef1c978d786e0f6b3a1510e0ac93ef59e0ddae2bc"},
+ {file = "PyYAML-6.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d2b04aac4d386b172d5b9692e2d2da8de7bfb6c387fa4f801fbf6fb2e6ba4673"},
+ {file = "PyYAML-6.0.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:e7d73685e87afe9f3b36c799222440d6cf362062f78be1013661b00c5c6f678b"},
+ {file = "PyYAML-6.0.1-cp311-cp311-win32.whl", hash = "sha256:1635fd110e8d85d55237ab316b5b011de701ea0f29d07611174a1b42f1444741"},
+ {file = "PyYAML-6.0.1-cp311-cp311-win_amd64.whl", hash = "sha256:bf07ee2fef7014951eeb99f56f39c9bb4af143d8aa3c21b1677805985307da34"},
+ {file = "PyYAML-6.0.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:855fb52b0dc35af121542a76b9a84f8d1cd886ea97c84703eaa6d88e37a2ad28"},
+ {file = "PyYAML-6.0.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:40df9b996c2b73138957fe23a16a4f0ba614f4c0efce1e9406a184b6d07fa3a9"},
+ {file = "PyYAML-6.0.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a08c6f0fe150303c1c6b71ebcd7213c2858041a7e01975da3a99aed1e7a378ef"},
+ {file = "PyYAML-6.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6c22bec3fbe2524cde73d7ada88f6566758a8f7227bfbf93a408a9d86bcc12a0"},
+ {file = "PyYAML-6.0.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:8d4e9c88387b0f5c7d5f281e55304de64cf7f9c0021a3525bd3b1c542da3b0e4"},
+ {file = "PyYAML-6.0.1-cp312-cp312-win32.whl", hash = "sha256:d483d2cdf104e7c9fa60c544d92981f12ad66a457afae824d146093b8c294c54"},
+ {file = "PyYAML-6.0.1-cp312-cp312-win_amd64.whl", hash = "sha256:0d3304d8c0adc42be59c5f8a4d9e3d7379e6955ad754aa9d6ab7a398b59dd1df"},
+ {file = "PyYAML-6.0.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:50550eb667afee136e9a77d6dc71ae76a44df8b3e51e41b77f6de2932bfe0f47"},
+ {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1fe35611261b29bd1de0070f0b2f47cb6ff71fa6595c077e42bd0c419fa27b98"},
+ {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:704219a11b772aea0d8ecd7058d0082713c3562b4e271b849ad7dc4a5c90c13c"},
+ {file = "PyYAML-6.0.1-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:afd7e57eddb1a54f0f1a974bc4391af8bcce0b444685d936840f125cf046d5bd"},
+ {file = "PyYAML-6.0.1-cp36-cp36m-win32.whl", hash = "sha256:fca0e3a251908a499833aa292323f32437106001d436eca0e6e7833256674585"},
+ {file = "PyYAML-6.0.1-cp36-cp36m-win_amd64.whl", hash = "sha256:f22ac1c3cac4dbc50079e965eba2c1058622631e526bd9afd45fedd49ba781fa"},
+ {file = "PyYAML-6.0.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:b1275ad35a5d18c62a7220633c913e1b42d44b46ee12554e5fd39c70a243d6a3"},
+ {file = "PyYAML-6.0.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:18aeb1bf9a78867dc38b259769503436b7c72f7a1f1f4c93ff9a17de54319b27"},
+ {file = "PyYAML-6.0.1-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:596106435fa6ad000c2991a98fa58eeb8656ef2325d7e158344fb33864ed87e3"},
+ {file = "PyYAML-6.0.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:baa90d3f661d43131ca170712d903e6295d1f7a0f595074f151c0aed377c9b9c"},
+ {file = "PyYAML-6.0.1-cp37-cp37m-win32.whl", hash = "sha256:9046c58c4395dff28dd494285c82ba00b546adfc7ef001486fbf0324bc174fba"},
+ {file = "PyYAML-6.0.1-cp37-cp37m-win_amd64.whl", hash = "sha256:4fb147e7a67ef577a588a0e2c17b6db51dda102c71de36f8549b6816a96e1867"},
+ {file = "PyYAML-6.0.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:1d4c7e777c441b20e32f52bd377e0c409713e8bb1386e1099c2415f26e479595"},
+ {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a0cd17c15d3bb3fa06978b4e8958dcdc6e0174ccea823003a106c7d4d7899ac5"},
+ {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:28c119d996beec18c05208a8bd78cbe4007878c6dd15091efb73a30e90539696"},
+ {file = "PyYAML-6.0.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7e07cbde391ba96ab58e532ff4803f79c4129397514e1413a7dc761ccd755735"},
+ {file = "PyYAML-6.0.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:49a183be227561de579b4a36efbb21b3eab9651dd81b1858589f796549873dd6"},
+ {file = "PyYAML-6.0.1-cp38-cp38-win32.whl", hash = "sha256:184c5108a2aca3c5b3d3bf9395d50893a7ab82a38004c8f61c258d4428e80206"},
+ {file = "PyYAML-6.0.1-cp38-cp38-win_amd64.whl", hash = "sha256:1e2722cc9fbb45d9b87631ac70924c11d3a401b2d7f410cc0e3bbf249f2dca62"},
+ {file = "PyYAML-6.0.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:9eb6caa9a297fc2c2fb8862bc5370d0303ddba53ba97e71f08023b6cd73d16a8"},
+ {file = "PyYAML-6.0.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:c8098ddcc2a85b61647b2590f825f3db38891662cfc2fc776415143f599bb859"},
+ {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5773183b6446b2c99bb77e77595dd486303b4faab2b086e7b17bc6bef28865f6"},
+ {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b786eecbdf8499b9ca1d697215862083bd6d2a99965554781d0d8d1ad31e13a0"},
+ {file = "PyYAML-6.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bc1bf2925a1ecd43da378f4db9e4f799775d6367bdb94671027b73b393a7c42c"},
+ {file = "PyYAML-6.0.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:04ac92ad1925b2cff1db0cfebffb6ffc43457495c9b3c39d3fcae417d7125dc5"},
+ {file = "PyYAML-6.0.1-cp39-cp39-win32.whl", hash = "sha256:faca3bdcf85b2fc05d06ff3fbc1f83e1391b3e724afa3feba7d13eeab355484c"},
+ {file = "PyYAML-6.0.1-cp39-cp39-win_amd64.whl", hash = "sha256:510c9deebc5c0225e8c96813043e62b680ba2f9c50a08d3724c7f28a747d1486"},
+ {file = "PyYAML-6.0.1.tar.gz", hash = "sha256:bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43"},
+]
+
+[metadata]
+lock-version = "2.0"
+python-versions = "^3.10"
+content-hash = "9c430e23d3186e8b6736a7e43bfe617b588f98f1c4cb8db00d97b96f6d8bae56"
diff --git a/pyproject.toml b/pyproject.toml
new file mode 100644
index 0000000..4dc1138
--- /dev/null
+++ b/pyproject.toml
@@ -0,0 +1,19 @@
+[tool.poetry]
+name = "dockerized"
+version = "0.21.0"
+description = "Seamlessly execute commands in a container"
+authors = ["Itamar Ben-Zaken "]
+license = "MIT License"
+readme = "README.md"
+
+[tool.poetry.dependencies]
+python = "^3.10"
+click = "^7.1.2"
+pyyaml = "^6.0.1"
+
+[tool.poetry.scripts]
+dockerized = 'dockerized.ui.cli:main'
+
+[build-system]
+requires = ["poetry-core"]
+build-backend = "poetry.core.masonry.api"
diff --git a/setup.py b/setup.py
deleted file mode 100644
index 55bea86..0000000
--- a/setup.py
+++ /dev/null
@@ -1,26 +0,0 @@
-from setuptools import setup, find_packages
-import json
-
-with open("README.md", "r") as fh:
- long_description = fh.read()
-
-version = "0.20.0"
-
-setup(
- name="dockerized",
- version=version,
- author="Itamar Ben-Zaken",
- author_email="benzaita@gmail.com",
- description="Seamlessly execute commands in a container",
- long_description=long_description,
- long_description_content_type="text/markdown",
- url="https://benzaita.github.io/dockerized-cli/index.html",
- packages=find_packages(),
- classifiers=[
- "Programming Language :: Python :: 3",
- "License :: OSI Approved :: MIT License",
- "Operating System :: OS Independent",
- ],
- python_requires='>=3.6',
- scripts=['bin/dockerized']
-)
diff --git a/tasks.py b/tasks.py
deleted file mode 100644
index 3c66663..0000000
--- a/tasks.py
+++ /dev/null
@@ -1,19 +0,0 @@
-from invoke import task
-
-
-@task
-def test(c):
- c.run('python -m unittest -v')
-
-
-@task
-def dist(c):
- c.run('cp dockerized.py bin/dockerized')
- c.run('rm -rf dist/')
- c.run('pipenv-setup sync')
- c.run('python setup.py sdist bdist_wheel')
-
-
-@task
-def bumpversion(c, part):
- c.run(f"bumpversion {part}")
diff --git a/test_dockerized.py b/test_dockerized.py
index 4f64da6..25d93be 100644
--- a/test_dockerized.py
+++ b/test_dockerized.py
@@ -6,6 +6,7 @@
from dockerized.test import ProjectAwareTestCase
+PRINT_COMMANDS = False
class AbstractEndToEndTest(ProjectAwareTestCase):
def tearDown(self) -> None:
@@ -16,9 +17,19 @@ def tearDown(self) -> None:
def run_dockerized(self, cmd_line, working_dir=None, project_dir=None, env=None):
safe_project_dir = project_dir or self.project_dirs[0]
this_file_path = os.path.dirname(os.path.realpath(__file__))
- dockerized = this_file_path + '/dockerized.py'
+ dockerized = f"PYTHONPATH={this_file_path} python -m dockerized.ui.cli"
cwd = safe_project_dir if working_dir is None else f"{safe_project_dir}/{working_dir}"
- process = subprocess.run(f"{dockerized} {cmd_line}", cwd=cwd, shell=True, capture_output=True, env=env)
+
+ if PRINT_COMMANDS:
+ print(f"> {cwd}: {dockerized} {cmd_line}")
+
+ process = subprocess.run(f"{dockerized} {cmd_line}", cwd=cwd, shell=True, capture_output=True, text=True, env=env)
+
+ if PRINT_COMMANDS:
+ print(f"EXIT CODE: {process.returncode}")
+ print(f"STDOUT: {process.stdout}")
+ print(f"STDERR: {process.stderr}")
+
return process.returncode, process.stdout, process.stderr
def assert_dockerized(self, command, expected_exit_code=None, fixture_name=None, working_dir=None, project_dir=None,
@@ -31,8 +42,8 @@ def assert_dockerized(self, command, expected_exit_code=None, fixture_name=None,
self.setup_project_dir(fixture_name, safe_project_dir)
exit_code, stdout, stderr = self.run_dockerized(command, working_dir, env=env)
- self.assertRegex(stderr.decode('utf-8'), re.compile(expected_stderr_regex, re.MULTILINE))
- self.assertRegex(stdout.decode('utf-8'), re.compile(expected_stdout_regex, re.MULTILINE))
+ self.assertRegex(stderr, re.compile(expected_stderr_regex, re.MULTILINE))
+ self.assertRegex(stdout, re.compile(expected_stdout_regex, re.MULTILINE))
self.assertEqual(expected_exit_code, exit_code)
@@ -42,7 +53,7 @@ def test_init_succeeds(self):
self.assert_dockerized(
command='init',
expected_exit_code=0,
- expected_stdout_regex=r'^created$',
+ expected_stdout_regex=r'^created',
expected_stderr_regex=r'.*'
)
@@ -60,15 +71,18 @@ def test_init_fails(self):
command='init',
expected_exit_code=1,
expected_stdout_regex=r'.*',
- expected_stderr_regex=r'^Refusing to overwrite .dockerized$'
+ expected_stderr_regex=r'^Refusing to overwrite .dockerized'
)
def test_compose_delegates_to_docker_compose(self):
self.assert_dockerized(
fixture_name='_init',
- command='compose ps --services',
+ command='compose version',
expected_exit_code=0,
- expected_stdout_regex=r'^dockerized$',
+
+ # Output is different on different versions of docker-compose
+ expected_stdout_regex=r'^[Dd]ocker[- ][Cc]ompose version',
+
expected_stderr_regex=r'.*'
)
@@ -78,7 +92,7 @@ def test_compose_exit_code(self):
command='compose kill foo',
expected_exit_code=1,
expected_stdout_regex=r'.*',
- expected_stderr_regex=r'^No such service: foo$'
+ expected_stderr_regex=r'^[Nn]o such service: foo'
)
def test_exec_exit_code(self):
@@ -95,14 +109,14 @@ def test_exec_pipes_stdout(self):
fixture_name='_init',
command='exec echo something out',
expected_exit_code=0,
- expected_stdout_regex=r'^something out$',
+ expected_stdout_regex=r'^something out',
expected_stderr_regex=r'.*',
)
def test_exec_pipes_stderr(self):
self.assert_dockerized(
fixture_name='_init',
- command='exec echo \'something err >&2\'',
+ command='exec echo something err >&2',
expected_exit_code=0,
expected_stdout_regex=r'.*',
expected_stderr_regex=r'something err',
@@ -113,7 +127,7 @@ def test_exec_takes_env_vars_from_docker_compose_file(self):
fixture_name='with_foo_env_var',
command='exec echo FOO=\\$FOO',
expected_exit_code=0,
- expected_stdout_regex=r'^FOO=1$',
+ expected_stdout_regex=r'^FOO=1',
expected_stderr_regex=r'.*',
)
@@ -122,7 +136,7 @@ def test_exec_passes_the_command_line_verbatim(self):
fixture_name='with_foo_env_var',
command='exec \'env FOO=2 | grep FOO\'',
expected_exit_code=0,
- expected_stdout_regex=r'^FOO=2$',
+ expected_stdout_regex=r'^FOO=2',
expected_stderr_regex=r'.*',
)
@@ -131,7 +145,7 @@ def test_exec_binds_project_dir(self):
fixture_name='with_files',
command='exec cat dir/file.txt',
expected_exit_code=0,
- expected_stdout_regex=r'^Hello world!$',
+ expected_stdout_regex=r'^Hello world!',
expected_stderr_regex=r'.*',
)
@@ -141,7 +155,7 @@ def test_exec_runs_from_sub_dir(self):
working_dir='dir',
command='exec cat file.txt',
expected_exit_code=0,
- expected_stdout_regex=r'^Hello world!$',
+ expected_stdout_regex=r'^Hello world!',
expected_stderr_regex=r'.*',
)
@@ -151,7 +165,7 @@ def test_exec_makes_the_entire_project_dir_available_in_the_container(self):
working_dir='dir',
command='exec cat ../file_in_project_root.txt',
expected_exit_code=0,
- expected_stdout_regex=r'^Hello from project root$',
+ expected_stdout_regex=r'^Hello from project root',
expected_stderr_regex=r'.*',
)
@@ -161,7 +175,7 @@ def test_exec_fails_when_not_in_project_sub_dir(self):
command='exec true',
expected_exit_code=1,
expected_stdout_regex=r'.*',
- expected_stderr_regex=r'^Not inside a Dockerized project directory. Did you run \'dockerized init\'\?$',
+ expected_stderr_regex=r'^Not inside a Dockerized project directory. Did you run \'dockerized init\'\?',
)
def test_exec_takes_command_with_args(self):
@@ -169,7 +183,7 @@ def test_exec_takes_command_with_args(self):
fixture_name='with_files',
command='exec id -u',
expected_exit_code=0,
- expected_stdout_regex=r'^0$',
+ expected_stdout_regex=r'^0',
expected_stderr_regex=r'.*',
)
@@ -186,8 +200,8 @@ def test_exec_in_two_dirs_does_not_conflict(self):
_, stdout_foo, _ = self.run_dockerized('exec \'echo $TEST_VAR\'', project_dir=foo_dir)
_, stdout_bar, _ = self.run_dockerized('exec \'echo $TEST_VAR\'', project_dir=bar_dir)
- self.assertEqual(b'foo\n', stdout_foo)
- self.assertEqual(b'bar\n', stdout_bar)
+ self.assertRegex(stdout_foo, re.compile(r'^foo', re.MULTILINE))
+ self.assertRegex(stdout_bar, re.compile(r'^bar', re.MULTILINE))
def test_exec_parallel_invocations_prepare_only_once(self):
project_dir = self.add_project_dir()
@@ -204,20 +218,22 @@ def test_exec_parallel_invocations_prepare_only_once(self):
results = [f.result() for f in futures]
exit_codes = [r[0] for r in results]
- stdouts = [r[1].decode('utf-8') for r in results]
- stderrs = [r[2].decode('utf-8') for r in results]
+ stdouts = [r[1] for r in results]
+ stderrs = [r[2] for r in results]
non_zero_exit_codes = [c for c in exit_codes if c != 0]
non_empty_stdouts = [s for s in stdouts if len(s) > 0]
- non_empty_stderrs = [s for s in stderrs if re.search(r'Creating network', s) is not None]
+ non_empty_stderrs = [s for s in stderrs if re.search(r'(Creating network|Network .* Creating)', s) is not None]
self.assertTrue(len(non_empty_stderrs) == 1,
f"Expected exactly one STDERR to be not empty, got {len(non_empty_stderrs)}:\n" +
'\n---\n'.join(non_empty_stderrs))
- self.assertTrue(len(non_empty_stdouts) == 0,
- f"Expected all STDOUT to be empty, got:\n" +
- '\n---\n'.join(non_empty_stdouts))
+ self.assertTrue(
+ # Output depends on the version of docker-compose
+ len(non_empty_stdouts) == 1 or len(non_empty_stdouts) == 0,
+ f"Expected exactly one STDOUT to be not empty, got {len(non_empty_stdouts)}:\n" +
+ '\n---\n'.join(non_empty_stdouts))
self.assertTrue(len(non_zero_exit_codes) == 0,
f"Expected all exit codes to be zero, got: {','.join(map(str, non_zero_exit_codes))}")
@@ -240,7 +256,7 @@ def test_allows_config_file(self):
self.assert_dockerized(
fixture_name='with_config',
command='exec true',
- expected_exit_code=0,
+ expected_exit_code=1,
expected_stdout_regex=r'.*',
expected_stderr_regex=r'.*',
)