I get the following error when I run the command docker-compose up
Could not locate Gemfile or .bundle/ directory
exited with code 10
Following is the code.
Note : I have added the parent directory of my code as a permanent shared folder to the VM using Oracle VM virtual box manager.
Any thoughts to resolve the issue.?
Dockerfile
FROM ruby:2.3.0
ENV HTTP_PROXY http://proxy.com:8080
ENV HTTPS_PROXY http://proxy.com:8080
RUN mkdir /student-api
WORKDIR /student-api
ADD Gemfile /student-api/Gemfile
ADD Gemfile.lock /student-api/Gemfile.lock
RUN bundle install
ADD . /student-api
Docker Compose
db:
image: postgres
ports:
- "5432:5432"
web:
build: .
command: bundle exec rails s -p 3000 -b '0.0.0.0'
volumes:
- .:/student-api
ports:
- "3000:3000"
links:
- db