mirror of
https://github.com/SikongJueluo/Mini-Nav.git
synced 2026-07-12 20:15:31 +08:00
feat(remote): unify remote execution workflow with env-based config
- Replace hardcoded SSH/docker targets with environment variables - Add remote-check, remote-dry, remote-test, remote-test-one recipes - Add remote cmd for arbitrary command execution in docker container
This commit is contained in:
33
.justfile
33
.justfile
@@ -1,4 +1,11 @@
|
||||
remote_root := "ial-gpu-workstation-1:/home/ial-pangyg/workspace/projects/mini-nav"
|
||||
set dotenv-required
|
||||
|
||||
export MSYS2_ARG_CONV_EXCL := "*"
|
||||
export MSYS2_ENV_CONV_EXCL := "*"
|
||||
|
||||
remote_ssh_target := env("REMOTE_SSH_TARGET")
|
||||
remote_docker_container := env("REMOTE_DOCKER_CONTAINER")
|
||||
remote_root := "$REMOTE_SSH_TARGET:$REMOTE_WORKDIR"
|
||||
rsync_flags := "-avLh --progress --stats --itemize-changes"
|
||||
upload_excludes := "--exclude-from=.rsyncignore"
|
||||
|
||||
@@ -30,10 +37,10 @@ ssh:
|
||||
-L 127.0.0.1:8385:127.0.0.1:8384 \
|
||||
-L 127.0.0.1:9098:127.0.0.1:9098 \
|
||||
-L 127.0.0.1:2718:172.30.0.2:2718 \
|
||||
ial-gpu-workstation-1
|
||||
{{ remote_ssh_target }}
|
||||
|
||||
docker:
|
||||
docker exec -it docker-ial-pangyg bash
|
||||
docker exec -it {{ remote_docker_container }} bash
|
||||
|
||||
marimo +notebook:
|
||||
uv run marimo edit {{ notebook }} --host 0.0.0.0 --port 2718 --no-token
|
||||
@@ -46,13 +53,17 @@ remove +packages:
|
||||
uv remove {{ packages }} --no-sync
|
||||
just sync-pkgs
|
||||
|
||||
add-dev +packages:
|
||||
uv add {{ packages }} --group dev --no-sync
|
||||
just sync-pkgs
|
||||
remote cmd:
|
||||
uv run python scripts/remote_docker_run.py run -- {{ quote(cmd) }}
|
||||
|
||||
remove-dev +packages:
|
||||
uv remove {{ packages }} --group dev --no-sync
|
||||
just sync-pkgs
|
||||
remote-check:
|
||||
uv run python scripts/remote_docker_run.py check
|
||||
|
||||
memory:
|
||||
MCP_ALLOW_ANONYMOUS_ACCESS=true memory server --http
|
||||
remote-dry cmd:
|
||||
uv run python scripts/remote_docker_run.py run --dry-run -- {{ quote(cmd) }}
|
||||
|
||||
remote-test:
|
||||
uv run python scripts/remote_docker_run.py run -- "uv run pytest -q"
|
||||
|
||||
remote-test-one path:
|
||||
uv run python scripts/remote_docker_run.py run -- "uv run pytest -q {{ path }}"
|
||||
|
||||
Reference in New Issue
Block a user