Skip to content

Support changing cache directory #44

@ghost

Description

Hi, guys.

Thank you for maintaining this awesome package!

I tried to use this package in an environment that it doesn't have write access to home directory ( Lambda function on Localstack), and got this error.

"ENOENT: no such file or directory, mkdir '/home/sbx_user1051/.ffbinaries-cache'

I have write access to /tmp directory, so changed LOCAL_CACHE_DIR manually then it worked.

Can it support changing cache directory officially?

for example, like

import { setCacheDir, downloadBinaries } from 'ffbinaries'

setCacheDir('/tmp/.ffbinaries')
downloadBinaries(["ffmpeg"])

Or, just for my usecase, it is enough to set through environment variables like FFBINARIES_CACHE_DIR="/tmp/.ffbinaries".

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions