fujin-cli 0.12.0__py3-none-any.whl → 0.12.1__py3-none-any.whl
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.
Potentially problematic release.
This version of fujin-cli might be problematic. Click here for more details.
- fujin/__init__.py +1 -1
- fujin/commands/_base.py +2 -1
- fujin/commands/deploy.py +1 -1
- fujin/config.py +3 -1
- fujin/connection.py +2 -2
- fujin/hooks.py +3 -2
- {fujin_cli-0.12.0.dist-info → fujin_cli-0.12.1.dist-info}/METADATA +1 -1
- {fujin_cli-0.12.0.dist-info → fujin_cli-0.12.1.dist-info}/RECORD +11 -11
- {fujin_cli-0.12.0.dist-info → fujin_cli-0.12.1.dist-info}/WHEEL +0 -0
- {fujin_cli-0.12.0.dist-info → fujin_cli-0.12.1.dist-info}/entry_points.txt +0 -0
- {fujin_cli-0.12.0.dist-info → fujin_cli-0.12.1.dist-info}/licenses/LICENSE.txt +0 -0
fujin/__init__.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "0.12.
|
|
1
|
+
__version__ = "0.12.1"
|
fujin/commands/_base.py
CHANGED
|
@@ -2,6 +2,7 @@ import importlib
|
|
|
2
2
|
from contextlib import contextmanager
|
|
3
3
|
from dataclasses import dataclass
|
|
4
4
|
from functools import cached_property
|
|
5
|
+
from typing import Generator
|
|
5
6
|
|
|
6
7
|
import cappa
|
|
7
8
|
|
|
@@ -47,7 +48,7 @@ class BaseCommand:
|
|
|
47
48
|
yield conn
|
|
48
49
|
|
|
49
50
|
@contextmanager
|
|
50
|
-
def app_environment(self) -> Connection:
|
|
51
|
+
def app_environment(self) -> Generator[Connection, None, None]:
|
|
51
52
|
with self.connection() as conn:
|
|
52
53
|
with conn.cd(self.app_dir):
|
|
53
54
|
with conn.prefix("source .appenv"):
|
fujin/commands/deploy.py
CHANGED
|
@@ -100,7 +100,7 @@ export PATH=".venv/bin:$PATH"
|
|
|
100
100
|
conn.run(f"echo '{appenv.strip()}' > {self.app_dir}/.appenv")
|
|
101
101
|
versioned_assets_dir = f"{self.app_dir}/v{version}"
|
|
102
102
|
if not skip_setup:
|
|
103
|
-
conn.run("rm -rf .venv")
|
|
103
|
+
conn.run("sudo rm -rf .venv")
|
|
104
104
|
conn.run("uv venv")
|
|
105
105
|
if self.config.requirements:
|
|
106
106
|
conn.run(f"uv pip install -r {versioned_assets_dir}/requirements.txt")
|
fujin/config.py
CHANGED
|
@@ -149,7 +149,9 @@ Path to the production environment file that will be copied to the host.
|
|
|
149
149
|
|
|
150
150
|
env
|
|
151
151
|
~~~
|
|
152
|
-
A string containing the production environment variables
|
|
152
|
+
A string containing the production environment variables. In combination with the secrets manager, this is most useful when
|
|
153
|
+
you want to automate deployment through a CI/CD platform like GitLab CI or GitHub Actions. For an example of how to do this,
|
|
154
|
+
check out the `integrations guide </integrations.html>`_
|
|
153
155
|
|
|
154
156
|
.. important::
|
|
155
157
|
|
fujin/connection.py
CHANGED
|
@@ -2,7 +2,7 @@ from __future__ import annotations
|
|
|
2
2
|
|
|
3
3
|
from contextlib import contextmanager
|
|
4
4
|
from functools import partial
|
|
5
|
-
from typing import TYPE_CHECKING
|
|
5
|
+
from typing import TYPE_CHECKING, Generator
|
|
6
6
|
|
|
7
7
|
import cappa
|
|
8
8
|
from fabric import Connection
|
|
@@ -32,7 +32,7 @@ def _get_watchers(host: HostConfig) -> list[Responder]:
|
|
|
32
32
|
|
|
33
33
|
|
|
34
34
|
@contextmanager
|
|
35
|
-
def host_connection(host: HostConfig) -> Connection:
|
|
35
|
+
def host_connection(host: HostConfig) -> Generator[Connection, None, None]:
|
|
36
36
|
connect_kwargs = None
|
|
37
37
|
if host.key_filename:
|
|
38
38
|
connect_kwargs = {"key_filename": str(host.key_filename)}
|
fujin/hooks.py
CHANGED
|
@@ -10,6 +10,7 @@ try:
|
|
|
10
10
|
except ImportError:
|
|
11
11
|
from enum import Enum
|
|
12
12
|
|
|
13
|
+
|
|
13
14
|
class StrEnum(str, Enum):
|
|
14
15
|
pass
|
|
15
16
|
|
|
@@ -36,9 +37,9 @@ class HookManager:
|
|
|
36
37
|
if not hooks_folder.exists():
|
|
37
38
|
return
|
|
38
39
|
self.hooks = {
|
|
39
|
-
h
|
|
40
|
+
h: f"./{hooks_folder / h.value}"
|
|
40
41
|
for h in Hook
|
|
41
|
-
if (hooks_folder / h.value).exists()
|
|
42
|
+
if (hooks_folder / h.value).exists()
|
|
42
43
|
}
|
|
43
44
|
|
|
44
45
|
def _run_hook(self, type_: Hook) -> None:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: fujin-cli
|
|
3
|
-
Version: 0.12.
|
|
3
|
+
Version: 0.12.1
|
|
4
4
|
Summary: Get your project up and running in a few minutes on your own vps.
|
|
5
5
|
Project-URL: Documentation, https://github.com/falcopackages/fujin#readme
|
|
6
6
|
Project-URL: Issues, https://github.com/falcopackages/fujin/issues
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
fujin/__init__.py,sha256=
|
|
1
|
+
fujin/__init__.py,sha256=PAuBI8I6F9Yu_86XjI2yaWn8QmCd9ZvK7tkZLWvEg-Q,23
|
|
2
2
|
fujin/__main__.py,sha256=KesDQurQ6HNMWBlxBLiSesgLHr6roUko3lgVh1pQNu8,1880
|
|
3
|
-
fujin/config.py,sha256=
|
|
4
|
-
fujin/connection.py,sha256=
|
|
3
|
+
fujin/config.py,sha256=veZyJ-s8mgk6yMsyBtoRUEbetjCS4d06Xi-_TTQHwOY,11844
|
|
4
|
+
fujin/connection.py,sha256=lL_YBpoQarqhwFb5AIFK6_RQBloXFl9Phyua1mLXSD0,2513
|
|
5
5
|
fujin/errors.py,sha256=74Rh-Sgql1YspPdR_akQ2G3xZ48zecyafYCptpaFo1A,73
|
|
6
|
-
fujin/hooks.py,sha256
|
|
6
|
+
fujin/hooks.py,sha256=-iTnWToDq6vg-qQPhay4IzZaSLKDxCHrpPvNX615BEU,1428
|
|
7
7
|
fujin/systemd.py,sha256=pHhnIkQppR9d_usP942DcSinADl-jpghPg-0jjvB3S4,6659
|
|
8
8
|
fujin/commands/__init__.py,sha256=g0b13vzidPUbxne_Zo_Wv5jpEmwCiSK4AokCinH9uo4,39
|
|
9
|
-
fujin/commands/_base.py,sha256=
|
|
9
|
+
fujin/commands/_base.py,sha256=lVIqlZsfM9cMbo4U3bK91n6YyWkLOBkkeIKoUk1cJt0,2245
|
|
10
10
|
fujin/commands/app.py,sha256=mazb4dCTdR5juh79bL3a9b68Nd6O8u_nR9IgYqQlqWE,5279
|
|
11
11
|
fujin/commands/config.py,sha256=WymGla-H2yduhLcYE1Nb6IJaFIj0S0KIhV9fBDCKsAw,2779
|
|
12
|
-
fujin/commands/deploy.py,sha256=
|
|
12
|
+
fujin/commands/deploy.py,sha256=aCMBLN3SnZENQm8DrtZzhP4OlaIbpGJJQWHvsAae2wg,5836
|
|
13
13
|
fujin/commands/docs.py,sha256=b5FZ8AgoAfn4q4BueEQvM2w5HCuh8-rwBqv_CRFVU8E,349
|
|
14
14
|
fujin/commands/down.py,sha256=aw_mxl_TMC66plKTXwlYP1W2XQBmHeROltQqOpQssyE,1577
|
|
15
15
|
fujin/commands/init.py,sha256=9yrja4YYFlJqEarN0ekg6yPd5niifPwvQ4i4wnC55a0,4007
|
|
@@ -32,8 +32,8 @@ fujin/secrets/system.py,sha256=Z5uNc2V3rcR75ffBnOsJywndoWuDcih88O9nPXIJ3U0,382
|
|
|
32
32
|
fujin/templates/simple.service,sha256=1Hp8GfpBevULTaBMHAimdBPPee4W1tStQyKP2xQ0hHE,329
|
|
33
33
|
fujin/templates/web.service,sha256=oOWLWonMl258xxNCYwGXHta427D86p2rH15cxkpHcLc,692
|
|
34
34
|
fujin/templates/web.socket,sha256=f-gq8g1loYkWEDq_30sNtgDdPX0lwddK0jQDQzHLuus,172
|
|
35
|
-
fujin_cli-0.12.
|
|
36
|
-
fujin_cli-0.12.
|
|
37
|
-
fujin_cli-0.12.
|
|
38
|
-
fujin_cli-0.12.
|
|
39
|
-
fujin_cli-0.12.
|
|
35
|
+
fujin_cli-0.12.1.dist-info/METADATA,sha256=91_DkybCmIOX6s2r0jxkV39IisQQwsV7hSQCnhatR1M,4603
|
|
36
|
+
fujin_cli-0.12.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
37
|
+
fujin_cli-0.12.1.dist-info/entry_points.txt,sha256=Y_TBtKt3j11qhwquMexZR5yqnDEqOBDACtresqQFE-s,46
|
|
38
|
+
fujin_cli-0.12.1.dist-info/licenses/LICENSE.txt,sha256=0QF8XfuH0zkIHhSet6teXfiCze6JSdr8inRkmLLTDyo,1099
|
|
39
|
+
fujin_cli-0.12.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|