wexample-wex-addon-dev-python 7.3.0__tar.gz → 7.4.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/PKG-INFO +4 -4
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/README.md +2 -2
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/pyproject.toml +2 -2
- {wexample_wex_addon_dev_python-7.3.0/src/wexample_wex_addon_dev_python/workdir → wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services}/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0/src/wexample_wex_addon_dev_python/workdir/__pycache__ → wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python}/__init__.py +0 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/app_service.py +85 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/commands/service/__init__.py +0 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/commands/service/install.py +42 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/commands/service/setup.py +58 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/docker/.wex.yml +2 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/docker/docker-compose.yml +17 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/samples/__init__.py +0 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/samples/docker/__init__.py +0 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/samples/docker/docker-compose.yml +5 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/samples/docker/entrypoint.sh +4 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/samples/docker/images/Dockerfile.base +16 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/samples/docker/images/Dockerfile.develop +7 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/samples/docker/images/__init__.py +0 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/service.yml +8 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/workdir/__init__.py +0 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/workdir/__pycache__/__init__.py +0 -0
- wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/workdir/mixin/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/__pycache__/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/check/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/check/mypy.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/check/pylint.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/check/pyright.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/check.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/format/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/format/black.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/format/isort.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/code/format.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/examples/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/examples/utils/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/examples/utils/some_example_type.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/examples/validate.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/commands/release/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/config_value/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/config_value/__pycache__/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/config_value/python_package_readme_config_value.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/const/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/const/__pycache__/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/const/package.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/const/python.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/file/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/file/__pycache__/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/file/python_app_iml_file.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/file/python_pyproject_toml_file.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/middleware/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/middleware/__pycache__/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/middleware/each_python_file_middleware.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/py.typed +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/python_addon_manager.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/resources/.wex.yml +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/resources/docker/Dockerfile.python-profiling +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/resources/package_publish_gitlab.yml +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/resources/readme_templates/tests.md.j2 +0 -0
- {wexample_wex_addon_dev_python-7.3.0/src/wexample_wex_addon_dev_python/workdir/mixin → wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/commands}/__init__.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/workdir/mixin/with_profiling_python_workdir_mixin.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/workdir/python_package_workdir.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/workdir/python_packages_suite_workdir.py +0 -0
- {wexample_wex_addon_dev_python-7.3.0 → wexample_wex_addon_dev_python-7.4.0}/src/wexample_wex_addon_dev_python/workdir/python_workdir.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: wexample-wex-addon-dev-python
|
|
3
|
-
Version: 7.
|
|
3
|
+
Version: 7.4.0
|
|
4
4
|
Summary: Python dev addon for wex
|
|
5
5
|
Author-Email: weeger <contact@wexample.com>
|
|
6
6
|
License: MIT
|
|
@@ -16,7 +16,7 @@ Requires-Dist: networkx
|
|
|
16
16
|
Requires-Dist: pylint
|
|
17
17
|
Requires-Dist: pyright
|
|
18
18
|
Requires-Dist: wexample-filestate-python>=6.4.0
|
|
19
|
-
Requires-Dist: wexample-wex-addon-app>=
|
|
19
|
+
Requires-Dist: wexample-wex-addon-app>=11.1.0
|
|
20
20
|
Provides-Extra: dev
|
|
21
21
|
Requires-Dist: pytest; extra == "dev"
|
|
22
22
|
Requires-Dist: pytest-cov; extra == "dev"
|
|
@@ -24,7 +24,7 @@ Description-Content-Type: text/markdown
|
|
|
24
24
|
|
|
25
25
|
# wex_addon_dev_python
|
|
26
26
|
|
|
27
|
-
Version: 7.
|
|
27
|
+
Version: 7.4.0
|
|
28
28
|
|
|
29
29
|
Python dev addon for wex
|
|
30
30
|
|
|
@@ -111,7 +111,7 @@ Visit the [Wexample Suite documentation](https://docs.wexample.com) for the comp
|
|
|
111
111
|
- pylint:
|
|
112
112
|
- pyright:
|
|
113
113
|
- wexample-filestate-python: >=6.4.0
|
|
114
|
-
- wexample-wex-addon-app: >=
|
|
114
|
+
- wexample-wex-addon-app: >=11.1.0
|
|
115
115
|
|
|
116
116
|
## Versioning & Compatibility Policy
|
|
117
117
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# wex_addon_dev_python
|
|
2
2
|
|
|
3
|
-
Version: 7.
|
|
3
|
+
Version: 7.4.0
|
|
4
4
|
|
|
5
5
|
Python dev addon for wex
|
|
6
6
|
|
|
@@ -87,7 +87,7 @@ Visit the [Wexample Suite documentation](https://docs.wexample.com) for the comp
|
|
|
87
87
|
- pylint:
|
|
88
88
|
- pyright:
|
|
89
89
|
- wexample-filestate-python: >=6.4.0
|
|
90
|
-
- wexample-wex-addon-app: >=
|
|
90
|
+
- wexample-wex-addon-app: >=11.1.0
|
|
91
91
|
|
|
92
92
|
## Versioning & Compatibility Policy
|
|
93
93
|
|
|
@@ -6,7 +6,7 @@ build-backend = "pdm.backend"
|
|
|
6
6
|
|
|
7
7
|
[project]
|
|
8
8
|
name = "wexample-wex-addon-dev-python"
|
|
9
|
-
version = "7.
|
|
9
|
+
version = "7.4.0"
|
|
10
10
|
description = "Python dev addon for wex"
|
|
11
11
|
authors = [
|
|
12
12
|
{ name = "weeger", email = "contact@wexample.com" },
|
|
@@ -25,7 +25,7 @@ dependencies = [
|
|
|
25
25
|
"pylint",
|
|
26
26
|
"pyright",
|
|
27
27
|
"wexample-filestate-python>=6.4.0",
|
|
28
|
-
"wexample-wex-addon-app>=
|
|
28
|
+
"wexample-wex-addon-app>=11.1.0",
|
|
29
29
|
]
|
|
30
30
|
|
|
31
31
|
[project.readme]
|
|
File without changes
|
|
File without changes
|
wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/services/python/app_service.py
ADDED
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from wexample_wex_addon_app.service.app_service import AppService as BaseAppService
|
|
4
|
+
|
|
5
|
+
PYPROJECT_TOML_CONTENT = """\
|
|
6
|
+
[build-system]
|
|
7
|
+
requires = ["pdm-backend"]
|
|
8
|
+
build-backend = "pdm.backend"
|
|
9
|
+
|
|
10
|
+
[project]
|
|
11
|
+
name = "app"
|
|
12
|
+
version = "0.0.1"
|
|
13
|
+
description = "Python app"
|
|
14
|
+
authors = [
|
|
15
|
+
{ name = "weeger", email = "contact@wexample.com" },
|
|
16
|
+
]
|
|
17
|
+
requires-python = ">=3.11,<3.14"
|
|
18
|
+
dependencies = [
|
|
19
|
+
]
|
|
20
|
+
|
|
21
|
+
[tool.pdm]
|
|
22
|
+
distribution = true
|
|
23
|
+
|
|
24
|
+
[tool.pdm.build]
|
|
25
|
+
package-dir = "src"
|
|
26
|
+
|
|
27
|
+
[[tool.pdm.build.packages]]
|
|
28
|
+
include = "app"
|
|
29
|
+
from = "src"
|
|
30
|
+
|
|
31
|
+
[tool.pdm.dev-dependencies]
|
|
32
|
+
dev = [
|
|
33
|
+
"pytest>=8.0.0",
|
|
34
|
+
]
|
|
35
|
+
|
|
36
|
+
[tool.pytest.ini_options]
|
|
37
|
+
testpaths = ["tests"]
|
|
38
|
+
pythonpath = ["src"]
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
MAIN_CONTENT = """\
|
|
42
|
+
if __name__ == "__main__":
|
|
43
|
+
print("OK")
|
|
44
|
+
"""
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
class AppService(BaseAppService):
|
|
48
|
+
def get_workdir_contribution(self) -> dict:
|
|
49
|
+
from wexample_filestate.const.disk import DiskItemType
|
|
50
|
+
|
|
51
|
+
return {
|
|
52
|
+
"children": [
|
|
53
|
+
{
|
|
54
|
+
"name": "pyproject.toml",
|
|
55
|
+
"type": DiskItemType.FILE,
|
|
56
|
+
"should_exist": True,
|
|
57
|
+
"default_content": PYPROJECT_TOML_CONTENT,
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"name": "src",
|
|
61
|
+
"type": DiskItemType.DIRECTORY,
|
|
62
|
+
"should_exist": True,
|
|
63
|
+
"children": [
|
|
64
|
+
{
|
|
65
|
+
"name": "app",
|
|
66
|
+
"type": DiskItemType.DIRECTORY,
|
|
67
|
+
"should_exist": True,
|
|
68
|
+
"children": [
|
|
69
|
+
{
|
|
70
|
+
"name": "__init__.py",
|
|
71
|
+
"type": DiskItemType.FILE,
|
|
72
|
+
"should_exist": True,
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"name": "__main__.py",
|
|
76
|
+
"type": DiskItemType.FILE,
|
|
77
|
+
"should_exist": True,
|
|
78
|
+
"default_content": MAIN_CONTENT,
|
|
79
|
+
},
|
|
80
|
+
],
|
|
81
|
+
}
|
|
82
|
+
],
|
|
83
|
+
},
|
|
84
|
+
]
|
|
85
|
+
}
|
|
File without changes
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING
|
|
4
|
+
|
|
5
|
+
from wexample_wex_core.const.globals import COMMAND_TYPE_SERVICE
|
|
6
|
+
from wexample_wex_core.decorator.command import command
|
|
7
|
+
|
|
8
|
+
if TYPE_CHECKING:
|
|
9
|
+
from wexample_wex_addon_app.service.app_service import AppService
|
|
10
|
+
from wexample_wex_core.context.execution_context import ExecutionContext
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
@command(
|
|
14
|
+
type=COMMAND_TYPE_SERVICE,
|
|
15
|
+
description="Register docker image build config for the python service",
|
|
16
|
+
)
|
|
17
|
+
def python__service__install(
|
|
18
|
+
context: ExecutionContext,
|
|
19
|
+
service: AppService,
|
|
20
|
+
) -> None:
|
|
21
|
+
project_name = service.app_workdir.get_project_name()
|
|
22
|
+
|
|
23
|
+
config_file = service.app_workdir.get_config_file()
|
|
24
|
+
config = config_file.read_config()
|
|
25
|
+
|
|
26
|
+
if config.search("docker.images").is_none():
|
|
27
|
+
config.set_by_path(
|
|
28
|
+
"docker.images",
|
|
29
|
+
{
|
|
30
|
+
"base": {
|
|
31
|
+
"dockerfile": ".wex/docker/images/Dockerfile.base",
|
|
32
|
+
"tag": f"{project_name}:local",
|
|
33
|
+
},
|
|
34
|
+
"develop": {
|
|
35
|
+
"dockerfile": ".wex/docker/images/Dockerfile.develop",
|
|
36
|
+
"tag": f"{project_name}-dev:local",
|
|
37
|
+
"depends_on": "base",
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
)
|
|
41
|
+
config_file.write_config(config)
|
|
42
|
+
context.io.log(f"Registered docker images for '{project_name}'")
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING
|
|
4
|
+
|
|
5
|
+
from wexample_wex_core.const.globals import COMMAND_TYPE_SERVICE
|
|
6
|
+
from wexample_wex_core.decorator.command import command
|
|
7
|
+
|
|
8
|
+
if TYPE_CHECKING:
|
|
9
|
+
from wexample_wex_addon_app.service.app_service import AppService
|
|
10
|
+
from wexample_wex_core.context.execution_context import ExecutionContext
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
@command(
|
|
14
|
+
type=COMMAND_TYPE_SERVICE,
|
|
15
|
+
description="Build python docker images if not already built (idempotent via lock)",
|
|
16
|
+
)
|
|
17
|
+
def python__service__setup(
|
|
18
|
+
context: ExecutionContext,
|
|
19
|
+
service: AppService,
|
|
20
|
+
) -> None:
|
|
21
|
+
import subprocess
|
|
22
|
+
|
|
23
|
+
from wexample_helpers.helpers.file import file_mkdir_as_real_user
|
|
24
|
+
from wexample_wex_addon_app.helpers.image_builds import (
|
|
25
|
+
load_builds,
|
|
26
|
+
resolve_build_order,
|
|
27
|
+
)
|
|
28
|
+
|
|
29
|
+
app_path = service.app_workdir.get_path()
|
|
30
|
+
lock_dir = app_path / ".wex" / "local" / "setup"
|
|
31
|
+
lock_file = lock_dir / "python.done"
|
|
32
|
+
|
|
33
|
+
if lock_file.exists():
|
|
34
|
+
return
|
|
35
|
+
|
|
36
|
+
try:
|
|
37
|
+
builds = load_builds(app_path)
|
|
38
|
+
except (FileNotFoundError, KeyError):
|
|
39
|
+
context.io.log("No docker.images in config.yml, skipping image build")
|
|
40
|
+
return
|
|
41
|
+
|
|
42
|
+
ordered = resolve_build_order(builds)
|
|
43
|
+
|
|
44
|
+
for build_name in ordered:
|
|
45
|
+
build = builds[build_name]
|
|
46
|
+
dockerfile = str(app_path / build["dockerfile"])
|
|
47
|
+
tag = build["tag"]
|
|
48
|
+
cmd = ["docker", "build", "-f", dockerfile, "-t", tag]
|
|
49
|
+
if "depends_on" in build:
|
|
50
|
+
parent_tag = builds[build["depends_on"]]["tag"]
|
|
51
|
+
cmd += ["--build-arg", f"BASE_IMAGE={parent_tag}"]
|
|
52
|
+
cmd.append(str(app_path))
|
|
53
|
+
context.io.log(f"Building image '{build_name}' → {tag}")
|
|
54
|
+
subprocess.run(cmd, check=True)
|
|
55
|
+
|
|
56
|
+
file_mkdir_as_real_user(lock_dir)
|
|
57
|
+
lock_file.write_text("done\n")
|
|
58
|
+
context.io.log("Python setup complete.")
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
services:
|
|
2
|
+
python:
|
|
3
|
+
container_name: ${APP_PROJECT_NAME}_python
|
|
4
|
+
image: ${APP_NAME}-dev:local
|
|
5
|
+
build:
|
|
6
|
+
context: ${APP_PATH}
|
|
7
|
+
dockerfile: ${APP_SETUP_PATH}docker/images/Dockerfile.develop
|
|
8
|
+
args:
|
|
9
|
+
BASE_IMAGE: ${APP_NAME}:local
|
|
10
|
+
command: [ "bash", "/opt/app/.wex/docker/entrypoint.sh" ]
|
|
11
|
+
volumes:
|
|
12
|
+
- ${APP_PATH}:/opt/app/
|
|
13
|
+
expose:
|
|
14
|
+
- "8000"
|
|
15
|
+
extends:
|
|
16
|
+
file: ${SERVICE_DEFAULT_COMPOSE}
|
|
17
|
+
service: default
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
FROM python:3.12-bookworm
|
|
2
|
+
|
|
3
|
+
WORKDIR /opt/app/
|
|
4
|
+
|
|
5
|
+
RUN useradd --uid 1000 owner --create-home \
|
|
6
|
+
&& adduser owner sudo \
|
|
7
|
+
&& mkdir -p /etc/sudoers.d \
|
|
8
|
+
&& echo "owner ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/owner
|
|
9
|
+
|
|
10
|
+
RUN pip install --no-cache-dir --upgrade pip setuptools wheel
|
|
11
|
+
|
|
12
|
+
COPY . /opt/app/
|
|
13
|
+
|
|
14
|
+
RUN pip install --no-cache-dir .
|
|
15
|
+
|
|
16
|
+
CMD ["bash"]
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
wexample_wex_addon_dev_python-7.4.0/src/wexample_wex_addon_dev_python/workdir/mixin/__init__.py
ADDED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|