最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

"no such file or directory" docker-compose on bind-mount volumes MacOS (Intel) - Stack Overflow

programmeradmin1浏览0评论

I had followed instruction of Strapi site "; to successfully create container of Strapi with Dockerfile.

Reference Branch of GitHub link

Now I can't create containers of Strapi by docker-compose.yml file with existing image of Strapi by just mentioned of Dockerfile and by instruction of Strapi site .

Errors Reference Branch of GitHub link

My Project Path Screenshot as

My Project Directory Structure Screenshot as

I'm using command podman-compose up --build -d to build the containers of MySQL & Strapi in an Pod of Podman, but failed and the building status & errors on Terminal as follows :

STEP 1/18: FROM node:18-alpine3.18
STEP 2/18: RUN apk update && apk add --no-cache build-base gcc autoconf automake zlib-dev libpng-dev nasm bash vips-dev git
--> Using cache 2c1101fbd69de271d02a75bd101c7445b9b681dc47be0a98c059d915f3bad9f9
--> 2c1101fbd69d
STEP 3/18: ARG NODE_ENV=development
--> Using cache a1abad233f94d979b0a58fe19699527e3a04ca44d5d0004999e09d67b29619fd
--> a1abad233f94
STEP 4/18: ENV NODE_ENV=${NODE_ENV}
--> Using cache 0c2283aa61e35507e7b9c481e696a5038ce684f3ea2e0d05209ccc31844a2ee7
--> 0c2283aa61e3
STEP 5/18: WORKDIR /opt/
--> Using cache b55c4649083ac42193055e1f86e774e1b5a654fbd02267faa2c464df5704444c
--> b55c4649083a
STEP 6/18: COPY package*.json ./
--> Using cache 5b2b0e7a0ecabb43912039d965e82470115e6209a6e47c4c9f5b1fdffc69d6fa
--> 5b2b0e7a0eca
STEP 7/18: RUN npm install -g node-gyp
--> Using cache acec4f0742fabb00ef911ae19bb973249787ab8636db3f88669f86252cca1dca
--> acec4f0742fa
STEP 8/18: RUN npm config set fetch-retry-maxtimeout 600000 -g && npm install
--> Using cache c16c741a6f6e8de977b29e987643a9d336b654b6338fb7da9bf64db0983c990d
--> c16c741a6f6e
STEP 9/18: ENV PATH=/opt/node_modules/.bin:$PATH
--> Using cache ca4d98a49c5628fdc2089b76166fbe6433f4be401074405bbd8c8978179cca45
--> ca4d98a49c56
STEP 10/18: WORKDIR /opt/app/
--> Using cache 8ecc7ae130bb06cc82bb8b046559ff8b2ab1c9b669e2fbb9bb1a244c423abdb6
--> 8ecc7ae130bb
STEP 11/18: COPY ./ .
--> Using cache 9df0123877502eeac3604fdade0edd5e97487f4dd410a05d6ac4100e1b71775f
--> 9df012387750
STEP 12/18: RUN chown -R node:node /opt/app/
--> Using cache b1429fddb430e0a625513e3927ab69a6bf9f0821632f42d9fb2e0b4b8b5a80e3
--> b1429fddb430
STEP 13/18: USER node
--> Using cache ce2d474aaa266e9e53e5a112eecbf1741c02ca6a37e209a396ec1a71d1c8f157
--> ce2d474aaa26
STEP 14/18: ENV GENERATE_SOURCEMAP=false
--> Using cache dbdc77bafba46b38345d315333f5bbfef476ee2bf789a658665813363642667f
--> dbdc77bafba4
STEP 15/18: ENV NODE_OPTIONS=--max_old_space_size=4096
--> Using cache 3363e22e15c1c945f2ef8f066de4d7aa64632d1a81fe19e07d4e3107634d6feb
--> 3363e22e15c1
STEP 16/18: RUN ["npm", "run", "build"]
--> Using cache fc5270c5cab9ca3656e6795a99f8c03faf58fc4c049379f7abd5c12d05e44ad4
--> fc5270c5cab9
STEP 17/18: EXPOSE 1337
--> Using cache a23d8e0ed8ac8e04b7123bd0dac5a286001c03bca63146b6efc6c6383bd8a8b0
--> a23d8e0ed8ac
STEP 18/18: CMD ["npm", "run", "develop"]
--> Using cache 4595a581dddb69e2b9efa34a5fc51c2ab7c506fe7084c7089489a0829a8f1c89
COMMIT image_mystrapi:latest
--> 4595a581dddb
Successfully tagged localhost/image_mystrapi:latest
4595a581dddb69e2b9efa34a5fc51c2ab7c506fe7084c7089489a0829a8f1c89
7766cdbdeba761a5196cd5ca06bdbbc32fcfcad50cea0e34121a91e57918e89f
3570eb98d7ac2f5ffd63190e7dcdc5244010e6008487952ddd25918f72252b61
Error: statfs /usr/local/var/www/root-podman-strapi-app/mysql-change-later-strapi/src: no such file or directory
Error: no container with name or ID "strapiContainer" found: no such container

System and Environment

ProductName: macOS (Intel)

ProductVersion: 14.7.4

BuildVersion: 23H420

Client: Podman Engine

Version: 5.4.1

API Version: 5.4.1

Go Version: go1.24.1

Built: Wed Mar 12 01:22:13 2025

Build Origin: brew

OS/Arch: darwin/amd64

Server: Podman Engine

Version: 5.4.1

API Version: 5.4.1

Go Version: go1.23.7

Git Commit: b79bc8afe796cba51dd906270a7e1056ccdfcf9e

Built: Tue Mar 11 08:00:00 2025

OS/Arch: linux/amd64

podman-compose version 1.3.0

podman version 5.4.1

Cause errors Image : Strapi and built by "custom", because Strapi has no official image.

发布评论

评论列表(0)

  1. 暂无评论