tangled
alpha
login
or
join now
matrixfurry.com
/
scripts
1
fork
atom
Various scripts that I maintain
1
fork
atom
overview
issues
pulls
pipelines
podman-remote-tcp (new script)
matrixfurry.com
7 months ago
9dafa890
428b8a98
verified
This commit was signed with the committer's
known signature
.
matrixfurry.com
SSH Key Fingerprint:
SHA256:68a4335QUqf4PR8E4jmNMaKH1SIxm7r+LLY9m/8nc/s=
+15
1 changed file
expand all
collapse all
unified
split
scripts
podman-remote-tcp.nu
+15
scripts/podman-remote-tcp.nu
···
1
1
+
#!/usr/bin/env nu
2
2
+
# SPDX-License-Identifier: AGPL-3.0-only
3
3
+
# Copyright (c) 2025 Shiloh Fen <shiloh@shilohfen.com>
4
4
+
5
5
+
def main [
6
6
+
remote?: string
7
7
+
...rest
8
8
+
--root (-r) # Connect to rootful socket
9
9
+
] {
10
10
+
if $root {
11
11
+
ssh -tL 2047:localhost:47 $remote ...$rest "sudo socat TCP-LISTEN:47,reuseaddr,fork UNIX-CONNECT:/run/podman/podman.sock"
12
12
+
} else {
13
13
+
ssh -tL 2047:localhost:2047 $remote ...$rest "socat TCP-LISTEN:2047,reuseaddr,fork UNIX-CONNECT:/run/user/1000/podman/podman.sock"
14
14
+
}
15
15
+
}