Skip to content

Change ADD in dockerfile syntax to support renaming output file #2571

Open
@mofosyne

Description

@mofosyne

Description

Say you got an existing line like

RUN wget -nv -O /usr/local/bin/nrfutil https://developer.nordicsemi.com/.pc-tools/nrfutil/x64-linux/nrfutil-v2.2

It would be nice to be able to rewrite it as

ADD https://developer.nordicsemi.com/.pc-tools/nrfutil/x64-linux/nrfutil-v2.2 /usr/local/bin/nrfutil

Where nrfutil-v2.2 is renamed to nrfutil

Right now, if I understand correctly you can only really do ADD https://developer.nordicsemi.com/.pc-tools/nrfutil/x64-linux/nrfutil-v2.2 /usr/local/bin/ as the definition of ADD only supports adding file to a folder path. Which would force you to add RUN mv nrfutil-v2.2 /usr/local/bin/nrfutil which is quite ugly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions