Plex on k8s installation problems

  • Hello community,

    I tried many times to install Plex on OMV 7,

    NO chance.

    See response


    An exception has been thrown during the rendering of a template ("The XPath query '//system/shares/sharedfolder[name='<MODIFY>']' does not return the requested number of 1 object(s).") in "manifest" at line 28.


    OMV\Config\DatabaseException: The XPath query '//system/shares/sharedfolder[name='<MODIFY>']' does not return the requested number of 1 object(s). in /usr/share/php/openmediavault/config/database.inc:200

    Stack trace:

    #0 /usr/share/openmediavault/engined/rpc/k8s.inc(320): OMV\Config\Database->getByFilter()

    #1 /usr/share/php/openmediavault/vendor/twig/twig/src/Environment.php(360) : eval()'d code(71): Engined\Rpc\OMVRpcServiceK8s->Engined\Rpc\{closure}()

    #2 /usr/share/php/openmediavault/vendor/twig/twig/src/Template.php(394): __TwigTemplate_9a21688a734022dd2aaac56fb9403eec->doDisplay()

    #3 /usr/share/php/openmediavault/vendor/twig/twig/src/Template.php(367): Twig\Template->displayWithErrorHandling()

    #4 /usr/share/php/openmediavault/vendor/twig/twig/src/Template.php(379): Twig\Template->display()

    #5 /usr/share/php/openmediavault/vendor/twig/twig/src/TemplateWrapper.php(38): Twig\Template->render()

    #6 /usr/share/php/openmediavault/vendor/twig/twig/src/Environment.php(280): Twig\TemplateWrapper->render()

    #7 /usr/share/openmediavault/engined/rpc/k8s.inc(352): Twig\Environment->render()

    #8 [internal function]: Engined\Rpc\OMVRpcServiceK8s->applyRecipe()

    #9 /usr/share/php/openmediavault/rpc/serviceabstract.inc(124): call_user_func_array()

    #10 /usr/share/php/openmediavault/rpc/rpc.inc(86): OMV\Rpc\ServiceAbstract->callMethod()

    #11 /usr/sbin/omv-engined(544): OMV\Rpc\Rpc::call()

    #12 {main}


    Next Twig\Error\RuntimeError: An exception has been thrown during the rendering of a template ("The XPath query '//system/shares/sharedfolder[name='<MODIFY>']' does not return the requested number of 1 object(s).") in "manifest" at line 28. in /usr/share/php/openmediavault/vendor/twig/twig/src/Template.php:408

    Stack trace:

    #0 /usr/share/php/openmediavault/vendor/twig/twig/src/Template.php(367): Twig\Template->displayWithErrorHandling()

    #1 /usr/share/php/openmediavault/vendor/twig/twig/src/Template.php(379): Twig\Template->display()

    #2 /usr/share/php/openmediavault/vendor/twig/twig/src/TemplateWrapper.php(38): Twig\Template->render()

    #3 /usr/share/php/openmediavault/vendor/twig/twig/src/Environment.php(280): Twig\TemplateWrapper->render()

    #4 /usr/share/openmediavault/engined/rpc/k8s.inc(352): Twig\Environment->render()

    #5 [internal function]: Engined\Rpc\OMVRpcServiceK8s->applyRecipe()

    #6 /usr/share/php/openmediavault/rpc/serviceabstract.inc(124): call_user_func_array()

    #7 /usr/share/php/openmediavault/rpc/rpc.inc(86): OMV\Rpc\ServiceAbstract->callMethod()

    #8 /usr/sbin/omv-engined(544): OMV\Rpc\Rpc::call()

    #9 {main}


    Other soft can be installed without problems

    What to do ?

    Thanks

  • Installation via Services, Kubernetes, Recipe:



    # The app can be reached at https://plex.<FQDN>:8443


    # Change the following variables to adapt the recipe to your needs.


    {% set runAsUser = 'nobody' %}


    {% set runAsGroup = 'users' %}


    {% set configSharedFolderName = '<MODIFY>' %}


    # !!! Only modify the following manifest if you need to make custom changes. !!!


    ---


    apiVersion: v1


    kind: Namespace


    metadata:


    name: plex-app


    ---


    apiVersion: v1


    kind: PersistentVolume


    metadata:


    name: config-dir


    labels:


    app.kubernetes.io/instance: plex-media-server


    app.kubernetes.io/name: plex-media-server


    spec:


    storageClassName: shared-folder


    capacity:


    storage: 2Gi


    hostPath:


    # Insert the name of the shared folder you want to use.


    # Make sure the configured UID/GID the container is running


    # with has access to that directory.


    path: {{ sharedfolder_path(configSharedFolderName) }}


    type: Directory


    accessModes:


    - ReadWriteMany


    ---


    apiVersion: "v1"


    kind: "PersistentVolumeClaim"


    metadata:


    name: config-dir


    namespace: plex-app


    labels:


    app.kubernetes.io/instance: plex-media-server


    app.kubernetes.io/name: plex-media-server


    spec:


    storageClassName: shared-folder


    accessModes:


    - "ReadWriteMany"


    resources:


    requests:


    storage: "2Gi"


    volumeName: config-dir


    ---


    apiVersion: helm.cattle.io/v1


    kind: HelmChart


    metadata:


    name: plex-media-server


    namespace: plex-app


    labels:


    app.kubernetes.io/instance: plex-media-server


    app.kubernetes.io/name: plex-media-server


    spec:


    repo: https://raw.githubusercontent.…exinc/pms-docker/gh-pages


    chart: plex-media-server


    targetNamespace: plex-app


    valuesContent: |-


    pms:


    configExistingClaim: config-dir


    ingress:


    enabled: false


    rclone:


    enabled: false


    service:


    type: ClusterIP


    extraEnv:


    # Specifies the UID for the process running in the container.


    PLEX_UID: "{{ uid(runAsUser) }}"


    # Specifies the GID for the process running in the container.


    # Defaults to `users`.


    PLEX_GID: "{{ gid(runAsGroup) }}"


    ---


    apiVersion: traefik.containo.us/v1alpha1


    kind: IngressRoute


    metadata:


    name: plex-media-server-websecure


    namespace: plex-app


    labels:


    app.kubernetes.io/instance: plex-media-server


    app.kubernetes.io/name: plex-media-server


    spec:


    entryPoints:


    - websecure


    routes:


    - match: Host(`plex.{{ fqdn() }}`)


    kind: Rule


    services:


    - name: plex-media-server


    port: 32400


    tls: {}

  • sorry, no experience here on kubernetes, i use plex on dockers, please edit first post title to add "kubernetes", and secon post to use code:


    this is my plex.yml file to use on docker plugin if you have interest:


    of course, you need to define variables in global section to reuse on other dockers so in my case PUID=1000 and GUID=100, etc...

  • ryecoaaron

    Changed the title of the thread from “FLex installation problems” to “Plex on k8s installation problems”.
    • Official Post

    You must have kept the same uuid then. Either way, it has been modified incorrectly.

    omv 7.7.9-1 sandworm | 64 bit | 6.11 proxmox kernel

    plugins :: omvextrasorg 7.0.2 | kvm 7.1.8 | compose 7.6.9 | cterm 7.8.7 | cputemp 7.0.2 | mergerfs 7.0.5 | scripts 7.2


    omv-extras.org plugins source code and issue tracker - github - changelogs


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!