apt
inside docker container?You need to run apt update
at first. Meanwhile, you need the root
permission to run apt
.
# In cmd console
docker run -v %cd%:/home image
# In powershell
docker run -v ${pwd}:/home image
You can use the editor(s) provided in the container, usually it would be nano
or vim
, which depends on what had been wrapped by the image author.
You can also editor files on your host machine with your favorite editor and mount them or copy them to the container.
See move docker to another drive
First, mac users do not need to specify uid, so please just run as a super user inside docker, i.e., without specifying -u
id -u:
id -g`` in the docker run command.
If it can not help, maybe there is some subtlety in the Mac general settings. Visit "System preferences > Security & Privacy > Files and Folders", and grant Docker the permission on various folders. Please see more on this link.
See https://yeasy.gitbook.io/docker_practice/install/mirror