mirror of
https://github.com/containers/podman.git
synced 2025-07-30 11:52:47 +08:00
Fix documentation of use of tcp connections
Fixes: https://github.com/containers/podman/issues/15430 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
@ -8,7 +8,7 @@ podman\-system\-service - Run an API service
|
||||
|
||||
## DESCRIPTION
|
||||
The **podman system service** command creates a listening service that will answer API calls for Podman. You may
|
||||
optionally provide an endpoint for the API in URI form. For example, *unix:///tmp/foobar.sock* or *tcp:localhost:8080*.
|
||||
optionally provide an endpoint for the API in URI form. For example, *unix:///tmp/foobar.sock* or *tcp://localhost:8080*.
|
||||
If no endpoint is provided, defaults will be used. The default endpoint for a rootful
|
||||
service is *unix:///run/podman/podman.sock* and rootless is *unix://$XDG_RUNTIME_DIR/podman/podman.sock* (for
|
||||
example *unix:///run/user/1000/podman/podman.sock*)
|
||||
|
@ -20,7 +20,7 @@ class APITestCase(unittest.TestCase):
|
||||
|
||||
APITestCase.podman = Podman()
|
||||
APITestCase.service = APITestCase.podman.open(
|
||||
"system", "service", "tcp:localhost:8080", "--time=0"
|
||||
"system", "service", "tcp://localhost:8080", "--time=0"
|
||||
)
|
||||
# give the service some time to be ready...
|
||||
time.sleep(2)
|
||||
|
@ -63,7 +63,7 @@ class TestApi(unittest.TestCase):
|
||||
podman(),
|
||||
"system",
|
||||
"service",
|
||||
"tcp:localhost:8080",
|
||||
"tcp://localhost:8080",
|
||||
"--log-level=debug",
|
||||
"--time=0",
|
||||
],
|
||||
|
@ -95,12 +95,12 @@ $c2[ ]\+tcp://localhost:54321[ ]\+true" \
|
||||
# we need for the server.
|
||||
${PODMAN%%-remote*} --root ${PODMAN_TMPDIR}/root \
|
||||
--runroot ${PODMAN_TMPDIR}/runroot \
|
||||
system service -t 99 tcp:localhost:$_SERVICE_PORT &
|
||||
system service -t 99 tcp://localhost:$_SERVICE_PORT &
|
||||
_SERVICE_PID=$!
|
||||
wait_for_port localhost $_SERVICE_PORT
|
||||
|
||||
_run_podman_remote info --format '{{.Host.RemoteSocket.Path}}'
|
||||
is "$output" "tcp:localhost:$_SERVICE_PORT" \
|
||||
is "$output" "tcp://localhost:$_SERVICE_PORT" \
|
||||
"podman info works, and talks to the correct server"
|
||||
|
||||
_run_podman_remote info --format '{{.Store.GraphRoot}}'
|
||||
|
@ -46,7 +46,7 @@ function _run_podman_remote() {
|
||||
|
||||
${PODMAN%%-remote*} --root ${PODMAN_TMPDIR}/root \
|
||||
--runroot ${PODMAN_TMPDIR}/runroot \
|
||||
system service -t 99 tcp:localhost:$_SERVICE_PORT &
|
||||
system service -t 99 tcp://localhost:$_SERVICE_PORT &
|
||||
_SERVICE_PID=$!
|
||||
wait_for_port localhost $_SERVICE_PORT
|
||||
|
||||
|
Reference in New Issue
Block a user