telepresence icon indicating copy to clipboard operation
telepresence copied to clipboard

Telepresence error when using method = inject-tcp

Open thetrebor opened this issue 3 years ago • 0 comments

What were you trying to do?

telepresence --method=inject-tcp --namespace XXX --swap-deployment YYY --run-shell It works without the inject-tcp method

What did you expect to happen?

I expected to be able to access cluster specific resources without needing to whitelist them all

What happened instead?

This window popped up with some log lines output. Guessing the proxy is failing.

(please tell us - the traceback is automatically included, see below. use https://gist.github.com to pass along full telepresence.log)

Automatically included information

Command line: ['/usr/local/bin/telepresence', '--method=inject-tcp', '--namespace', 'sandbox', '--swap-deployment', 'zeusbox', '--run-shell'] Version: 0.109 Python version: 3.8.6 (default, Dec 6 2020, 17:39:48) [Clang 12.0.0 (clang-1200.0.32.27)] kubectl version: Client Version: v1.20.4-dirty // Server Version: v1.19.6-eks-49a6c0 oc version: (error: [Errno 2] No such file or directory: 'oc') OS: Darwin trebor-imac 20.3.0 Darwin Kernel Version 20.3.0: Thu Jan 21 00:07:06 PST 2021; root:xnu-7195.81.3~1/RELEASE_X86_64 x86_64

Traceback (most recent call last):
  File "/usr/local/bin/telepresence/telepresence/cli.py", line 135, in crash_reporting
    yield
  File "/usr/local/bin/telepresence/telepresence/main.py", line 81, in main
    user_process = launch(
  File "/usr/local/bin/telepresence/telepresence/outbound/setup.py", line 64, in launch
    return launch_inject(runner_, command, socks_port, env)
  File "/usr/local/bin/telepresence/telepresence/outbound/local.py", line 120, in launch_inject
    torsocks_env = set_up_torsocks(runner, socks_port)
  File "/usr/local/bin/telepresence/telepresence/outbound/local.py", line 71, in set_up_torsocks
    raise RuntimeError("SOCKS network proxying failed to start...")
RuntimeError: SOCKS network proxying failed to start...

Logs:

ket.socket().connect(('"'"'kubernetes.default'"'"', 443))'
  32.3 TEL | [118] exit -11 in 0.04 secs.
  32.4 TEL | [119] Running: torsocks python3 -c 'import socket; socket.socket().connect(('"'"'kubernetes.default'"'"', 443))'
  32.4 TEL | [119] exit -11 in 0.04 secs.
  32.5 TEL | [120] Running: torsocks python3 -c 'import socket; socket.socket().connect(('"'"'kubernetes.default'"'"', 443))'
  32.6 TEL | [120] exit -11 in 0.04 secs.
  32.7 TEL | [121] Running: torsocks python3 -c 'import socket; socket.socket().connect(('"'"'kubernetes.default'"'"', 443))'
  32.7 TEL | [121] exit -11 in 0.04 secs.
  32.8 TEL | [122] Running: torsocks python3 -c 'import socket; socket.socket().connect(('"'"'kubernetes.default'"'"', 443))'
  32.9 TEL | [122] exit -11 in 0.04 secs.
  33.0 TEL | [123] Running: torsocks python3 -c 'import socket; socket.socket().connect(('"'"'kubernetes.default'"'"', 443))'
  33.0 TEL | [123] exit -11 in 0.04 secs.
  33.0 TEL | END SPAN local.py:42(set_up_torsocks)   15.0s

thetrebor avatar Mar 18 '21 16:03 thetrebor