1

我们正面临分发包作曲家的问题。我们的目标是实现 DDEV + Composer + Distribution Package + helhum/typo3-secure-web(感谢@helhum 提供如此出色的安全解决方案)。

问题/问题

当尝试访问后端时它不起作用,检查这个带有 CSS/JS 的屏幕截图https://i.imgur.com/lI5IGCE.png是不可访问的,似乎是一些目录结构(私有/公共)导致问题。

设置方法

第 1 步:创建项目的文件夹

mkdir my-typo3-site
cd my-typo3-site

第二步:配置PHP版本

ddev config --project-type php --php-version 7.2

第 3 步:设置 TYPO3 最新版本

ddev composer create typo3/cms-base-distribution ^9 --no-interaction
ddev config --project-type typo3
ddev start

第 5 步:Composer.json,设置私人和公共文件夹

"extra": {
   "typo3/cms": {
       "root-dir": "private",
       "web-dir": "public"
   }
}

第 4 步:使用私有和公共文件夹结构保护您的 TYPO3

ddev composer require helhum/typo3-secure-web

第 5 步:创建 FIRST_INSTALL 文件

touch private/FIRST_INSTALL

第 6 步:TYPO3 安装向导(成功)

作曲家

由typo3/cms-base-distribution 生成的作曲家代码^9

{
    "repositories": [
        { "type": "composer", "url": "https://composer.typo3.org/" }
    ],
    "name": "typo3/cms-base-distribution",
    "description" : "TYPO3 CMS Base Distribution",
    "license": "GPL-2.0-or-later",
    "config": {
        "platform": {
            "php": "7.2"
        }
    },
    "require": {
        "helhum/typo3-console": "^5.5.5",
        "typo3/minimal": "^9.5",
        "typo3/cms-about": "^9.5",
        "typo3/cms-adminpanel": "^9.5",
        "typo3/cms-belog": "^9.5",
        "typo3/cms-beuser": "^9.5",
        "typo3/cms-felogin": "^9.5",
        "typo3/cms-fluid-styled-content": "^9.5",
        "typo3/cms-form": "^9.5",
        "typo3/cms-impexp": "^9.5",
        "typo3/cms-info": "^9.5",
        "typo3/cms-redirects": "^9.5",
        "typo3/cms-reports": "^9.5",
        "typo3/cms-rte-ckeditor": "^9.5",
        "typo3/cms-setup": "^9.5",
        "typo3/cms-seo": "^9.5",
        "typo3/cms-sys-note": "^9.5",
        "typo3/cms-t3editor": "^9.5",
        "typo3/cms-tstemplate": "^9.5",
        "typo3/cms-viewpage": "^9.5",
        "helhum/typo3-secure-web": "^0.2.8"
    },
    "scripts":{
        "typo3-cms-scripts": [
            "typo3cms install:fixfolderstructure",
            "typo3cms install:generatepackagestates"
        ],
        "post-autoload-dump": [
            "@typo3-cms-scripts"
        ]
    },
    "extra": {
        "typo3/cms": {
            "root-dir": "private",
            "web-dir": "public"
        }
    }
}

笔记

ddev composer require typo3/minimal 一切正常:^9 它只会导致分发包出现问题。

分发包可能有什么问题?我会很感激你的反馈。非常感谢您的时间!

4

1 回答 1

2

Hurray,刚刚解决了这个问题!这只是改变/遵循订单的问题,如下所示:

Step 1: Create a project's folder
Step 2: Configure PHP version
Step 3: Composer distribution package
Step 4: Create FIRST_INSTALL file
Step 5: TYPO3 Installation Wizard
Step 6: Composer.json, Setup private and public folders
Step 7: Secure your TYPO3 with folder structure private and public
Step 7: ddev composer require helhum/typo3-secure-web

欢呼!再次感谢@Helhum 提供如此安全的 TYPO3 解决方案 :)

激励人们确保安全

干杯,

桑杰

于 2019-04-25T10:02:05.887 回答