【发布时间】:2020-09-17 12:23:05
【问题描述】:
我正忙着建立一个 dockerized 环境来为 Magento 开发 PHP。 我使用的图像如下:alexcheng/magento2。 用于此的 git 存储库确实包含一个安装脚本。 当我运行“docker-compose up -d”时,一切正常,但每次容器出现故障时我都必须重新安装 Magento。
关于如何处理这个问题的任何建议?我是一个使用 docker 的新手,但我无法想象你每次都必须重新安装它。
注意,我认为这与数据持久性无关,因为已配置卷。当我在 Dockerfile "RUN install-magento" 中包含一行时,我在构建时收到以下错误:
/usr/bin/env: ‘bash\r’: No such file or directory
The command '/bin/sh -c install-magento' returned a non-zero code: 127
任何指导将不胜感激。谢谢。
【问题讨论】:
标签: wordpress bash docker magento docker-compose