表題について。
以下、エラー
db uses an image, skipping Building web [+] Building 0.9s (6/9) => [internal] load build definition from Dockerfile 0.0s => => transferring dockerfile: 38B 0.0s => [internal] load .dockerignore 0.1s => => transferring context: 2B 0.0s => [internal] load metadata for docker.io/library/ruby:2.7 0.0s => CACHED [1/5] FROM docker.io/library/ruby:2.7 0.0s => ERROR [internal] load build context 0.0s => => transferring context: 5.92kB 0.0s => CANCELED [2/5] RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-k 0.6s ------ > [internal] load build context: ------ error from sender: open /home/junpei/programing/rails_docker/src/db/mysql_data/#innodb_temp: permission denied ERROR: Service 'web' failed to build : Build failed
ちなみに、docker-compose.ymlは↓
version: '3' services: db: image: mysql:8.0 command: --default-authentication-plugin=mysql_native_password volumes: - ./src/db/mysql_data:/var/lib/mysql environment: MYSQL_ROOT_PASSWORD: password web: build: . command: bundle exec rails s -p 3000 -b '0.0.0.0' volumes: - ./src:/app ports: - "3000:3000" depends_on: - db
解決策もですが、
permission deniedが起こる理由なども教えていただけると助かります。
volumesが関係してそうな気はしてるのですが・・
回答1件
あなたの回答
tips
プレビュー