Skip to content
This repository was archived by the owner on Apr 28, 2020. It is now read-only.
This repository was archived by the owner on Apr 28, 2020. It is now read-only.

Documentation's "apt-get" fails as the user is not root #252

@tennox

Description

@tennox

I copied from the documentation:

FROM codercom/ubuntu-dev-node12:latest
RUN apt-get update && apt-get install -y \
        bsdtar \
    && rm -rf /var/lib/apt/lists/*

But the command fails:

E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied)
E: Unable to lock directory /var/lib/apt/lists/

Doing the same with sudo works:

FROM codercom/ubuntu-dev-node12:latest
RUN sudo apt-get update && sudo apt-get install -y \
        bsdtar \
    && sudo rm -rf /var/lib/apt/lists/*

Sail version: v1.1.0
Code-Server version: 2.1692-vsc1.39.2 e14362f3224c101585a26bf7ee5fa6e3bf425046 x64
Docker image version: 587ef9bdcb39f9edec99034726cd379683646de7f089896257dee97c4f0a0894

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions