apiVersion: v1
data:
  ServerConfig.json: |
    {
      "BasePathOverride": "{{ .Values.jackett.ingress.path }}"
    }
  init-jackett.sh: |
    #!/bin/bash
    echo "### Initializing config ###"
    if [ ! -f /jackett-config/ServerConfig.json ]; then
      cp -n /init-jackett/ServerConfig.json /jackett-config/ServerConfig.json
      echo "### No configuration found, intialized with default settings ###"
    fi
kind: ConfigMap
metadata:
  name: init-jackett-cm
