重新渲染图像
您可以使用 InstallTool(维护 › 删除临时资产)重新渲染图像。
权限
您应该考虑适合您的用例的权限概念。
我只是建议我如何做到这一点 - 还有许多其他同样可能的方法。
找出您的网络服务器使用的用户组
# search for php-fpm (or apache, or nginx, ... depending on which process runs PHP when accessed via the web on your server)
sudo ps -o command,user,group -p $(pgrep php-fpm)
将更改文件的用户放入同一组
这可能是您用于部署到服务器的用户,运行 FTP 守护程序的用户,...
sudo usermod -a -G WEBSERVER_GROUP YOUR_USERNAME
在 Web 应用目录上设置用户/组/权限
cd YOUR_APP_ROOT_DIR # e.g. /var/www/my_typo3
sudo chown -R WEBSERVER_USER:WEBSERVER_GROUP .
sudo find . -type f -exec chmod 660 {} \;
sudo find . -type d -exec chmod 2770 {} \;
这也会在目录上设置 setgid 位,这意味着新创建的子目录将具有相同的组。
确保也使用这些权限创建新文件
检查您的用户(或 FTP 守护程序,或...)创建的新文件是否会授予该组的完全权限!
umask
# that should start with 000 - e.g. 0002 is OK, 0007 would be most secure
如果错误(常见:0022),用umask 0002. 最容易持久化的通常是设置在 /etc/profile 或 ~/.bashrc 中。
还要确保 TYPO3 为组提供完整的写入权限并设置 setgid:
# In LocalConfiguration.php: (or wherever you set your TYPO3 configuration):
SYS/fileCreateMask = '0660' # you can ignore the last digit, 0 for maximum security
SYS/folderCreateMask = '2770' # you can ignore the last digit
检查
注销并重新登录。
umask # should be 000x
groups # should include the webserver group
# create files and folders with your user
# create files and folders in TYPO3 "File List" module and check permissions
这应该是一个安全的设置,对于遇到权限问题非常有弹性。它允许从 IDE 直接上传。它允许多个用户/守护进程更改文件。