Skip to content

Providing an option to mention tempDirectory instead of relying on tmp directory provided by os.TempDir #287

@pckvcode

Description

@pckvcode

What would you like to be added:
Providing an option to mention tempDirectory instead of relying on tmp directory provided by os.TempDir when GetImage

func GetImage(ctx context.Context, imgStr string, options ...Option) (*image.Image, error) {

Why is this needed:
We had a requirement where a customer wants to mention tempDirectory to be used by stereoscope while getting a docker image.

Additional context:

I examined the Stereoscope code to see if we could set a custom tempDir, but currently, that option isn’t available.

Here we are using global variable rootTempDirGenerator and not exposed to change.

var rootTempDirGenerator = file.NewTempDirGenerator("stereoscope")

Can we provide an option to update rootLocation in TempDirGenerator

rootLocation string

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    Status

    Ready

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions