Skip to content

[BUG] TMPDIR not quoted in init-plex-chown/run script #458

Description

@amonkarsidhant

Current Behavior

In root/etc/s6-overlay/s6-rc.d/init-plex-chown/run, line 8 uses mkdir -p ${TMPDIR} without quoting the variable. While the default value (/run/plex-temp) doesn't contain spaces, if a user sets TMPDIR to a path with spaces, the mkdir command will fail or create the wrong directory.

Expected Behavior

TMPDIR should be quoted consistently, like it is on line 6 where rm -rf "${TMPDIR}" is used.

Steps To Reproduce

  1. Set TMPDIR=/path with spaces/plex-temp in docker create/run command
  2. Start the container
  3. The mkdir -p command will fail or create incorrect directories

Environment

  • OS: Any
  • How docker service was installed: Any
  • CPU architecture: x86-64 or arm64
  • Docker creation: Any docker create/run command with TMPDIR containing spaces

Container logs

N/A - this is a code quality issue

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status
    Issues

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions