1

127742f30f6da12d76c21c70c19b617e231b06e2cd8cf635cd690f7fb7b51248 docker: Error response from daemon: Container command not found or does not exist..

FROM tutum/lamp:latest

ENV APP_DEBUG true
ENV APP_KEY test_key_value

ADD mysql-setup.sh /mysql-setup.sh
RUN chmod 755 /mysql-setup.sh

# Make ssh dir
RUN rm -rf /root/.ssh && mkdir /root/.ssh/

# Copy over private key, and set permissions
ADD id_rsa /root/.ssh/id_rsa

# Create known_hosts
RUN touch /root/.ssh/known_hosts
# Add bitbuckets key
RUN ssh-keyscan git.mevu.gg >> /root/.ssh/known_hosts

# Clone the conf files into the docker container
RUN rm -rf /app && git clone [email protected] /app

EXPOSE 80 3306
CMD ["/run.sh"]

RUN cd /app && composer install --prefer-dist

ENV DB_HOST localhost
ENV DB_DATABASE application_api
ENV DB_USERNAME root
ENV DB_PASSWORD=

ENV CACHE_DRIVER file
ENV SESSION_DRIVER file
ENV QUEUE_DRIVER sync

ENV MAIL_DRIVER smtp
ENV MAIL_HOST mailtrap.io
ENV MAIL_PORT 2525

Im not sure why this is happening. the build is successful.

I am using the command:

docker run -d -p 80:80 -p 3306:3306 kevs/app .

2 Answers 2

3

I think you are mixing build and run command concepts.

Build command builds the docker images that will be named as "kevs/app" and it will take the dockerfile in your current directory "."

$ docker build -t kevs/app .

After that, you can run that container:

$ docker run -d -p 80:80 -p 3306:3306 kevs/app
2

Try changing your docker run command to: docker run -d -p 80:80 -p 3306:3306 kevs/app

Not the answer you're looking for? Browse other questions tagged or ask your own question.