communication between polipo and tor kubernetes deployment

3/14/2019

Where can I add socksParentProxy in Kubernetes deployment file to communicate polipo with tor. I already created tor service tor:9150 and tor deployment. Here is a my YAML file:

apiVersion: apps/v1beta1 
kind: Deployment
metadata:
    name: polipo-deployment
    labels: 
        app: myauto
spec:
    selector:
        matchLabels:
          name: polipo-pod
          app: myauto
    template:
        metadata:
            name: polipo-deployment
            labels:
                name: polipo-pod
                app: myauto
        spec:
           containers:
              - env:
                    - name: socksParentProxy
                      value: tor:9150
                name: polipo
                image: 'clue/polipo'
                ports: 
                  - containerPort: 8123  
    replicas: 1
-- Giorgi Maisuradze
kubernetes
polipo
tor
yaml

1 Answer

5/13/2019

As in the documentation, you should use args:

containers:
    name: polipo
    image: 'clue/polipo'
    args: ["socksParentProxy=tor:9150"]
    ports: 
        - containerPort: 8123
-- BartoszKP
Source: StackOverflow