PrestaShop 1.7配置,对appParameters.php的权限被拒绝

时间:2019-10-26 09:03:54

标签: php docker docker-compose prestashop prestashop-1.7

我安装prestashop 1.7.6.0时遇到问题 通过docker-compose进行的安装本身可以正确通过,在配置此类实例时,在第三步会收到有关缺少文件权限的错误。

我不确定如何执行此安装,而无需手动授予该文件的权限,即

docker exec -it ID_CONTAINER / bin / bash
chmod 667 /var/www/html/var/cache/prod/appParameters.php

请帮助。

下面是我的docker-compose.yml

version: '3.3'
services:
  db:
    image: mysql:5.7
    volumes:
      - /var/lib1/mysql
    restart: always
    environment:
      MYSQL_ROOT_PASSWORD: admin
      MYSQL_DATABASE: ps
      MYSQL_USER: ps
      MYSQL_PASSWORD: ps

  prestashop:
    #build: .
    image: prestashop/prestashop-git:7
    depends_on:
      - db
    ports:
      - "8081:80"
    restart: always
    environment:
      PS_INSTALL_AUTO: 1
      PS_ERASE_DB: 0
      DB_SERVER: db
      DB_USER: ps
      DB_PASSWD: ps
      DB_NAME: ps
      PS_DEV_MODE: 1
      PS_DOMAIN: localhost:8080
      PS_FOLDER_ADMIN: admin123
      PS_FOLDER_INSTALL: install123
    volumes:
      - /var/www/html

已安装并可以开始,但下一步是配置,

db_1          | Version: '5.7.28'  socket: '/var/run/mysqld/mysqld.sock'  port: 3306  MySQL Community Server (GPL)
prestashop_1  | [Sat Oct 26 08:35:29.065962 2019] [:error] [pid 17] [client 172.19.0.1:57442] PHP Warning:  require_once(/var/www/html/var/cache/prod/appParameters.php): failed to open stream: Permission denied in /var/www/html/config/bootstrap.php on line 87
prestashop_1  | [Sat Oct 26 08:35:29.066041 2019] [:error] [pid 17] [client 172.19.0.1:57442] PHP Fatal error:  require_once(): Failed opening required '/var/www/html/var/cache/prod/appParameters.php' (include_path='/var/www/html/vendor/pear/pear_exception:/var/www/html/vendor/pear/console_getopt:/var/www/html/vendor/pear/pear-core-minimal/src:/var/www/html/vendor/pear/archive_tar:.:/usr/local/lib/php') in /var/www/html/config/bootstrap.php on line 87

0 个答案:

没有答案