I have a very simple dockerfile based on the debian image, and I'm currently only installing the vim
package. But somehow I can't execute the vim
command inside the container. I have tried several base images (debian, ubuntu and alpine) but they all seem to have the same issue.
Does anybody have an idea about what I'm doing wrong?
Dockerfile:
FROM debian:8.5
RUN apt-get update && apt-get install -y vim
docker-compose.yml:
version: '2'
services:
web:
container_name: frontend
build: .
ports:
- '127.0.0.1:1337:80'
The result after building and executing the container:
$ docker-compose up -d && docker exec -it frontend bash
root@06ebc89b2706:/# vim
bash: vim: command not found