summaryrefslogtreecommitdiff
path: root/roles/streaming/handbrake/templates/pod-spec.yml.j2
blob: 550c80ad40ae5d7ae6d0482f177aa7ae793f7b38 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
containers:
- name: handbrake
  image: jlesage/handbrake:{{ handbrake_image_version }}
  imagePullPolicy: Always
  terminationGracePeriodSeconds: 120
  securityContext:
    privileged: true
  env:
  - name: USER_ID
    value: '990'
  - name: GROUP_ID
    value: '990'
  - name: KEEP_APP_RUNNING
    value: '1'
  - name: DISPLAY_WIDTH
    value: '{{ handbrake_web_ui_width }}'
  - name: DISPLAY_HEIGHT
    value: '{{ handbrake_web_ui_height }}'

  volumeMounts:
{% if handbrake_enable_hardware_encoding %}
  - name: dri-device
    mountPath: /dev/dri
{% endif %}
  - name: config
    mountPath: /config
  - name: storage
    mountPath: /storage
    readOnly: yes
  - name: watch
    mountPath: /watch
  - name: output
    mountPath: /output
  ports:
  - containerPort: 5800
    hostPort: {{ handbrake_web_port }}

volumes:
{% if handbrake_enable_hardware_encoding %}
- name: dri-device
  hostPath:
    path: /dev/dri
{% endif %}
- name: config
  hostPath:
    path: "{{ handbrake_base_path }}/{{ handbrake_inst_name }}/config"
    type: Directory
- name: storage
  hostPath:
    path: "{{ handbrake_base_path }}/{{ handbrake_inst_name }}/storage"
    type: Directory
- name: watch
  hostPath:
    path: "{{ handbrake_base_path }}/{{ handbrake_inst_name }}/watch"
    type: Directory
- name: output
  hostPath:
    path: "{{ handbrake_base_path }}/{{ handbrake_inst_name }}/output"
    type: Directory