简体   繁体   English

Google APP Engine PHP 应用程序上的警告 mkdir() 权限被拒绝

[英]Warning mkdir() Permission Denied on Google APP Engine PHP Application

I am running CodeIgniter PHP Framework on Google APP Engine using flex environment.我正在使用 flex 环境在 Google APP Engine 上运行 CodeIgniter PHP 框架。 Everything is going well except for one small issue, I unable to create folder and upload files because of mkdir file permission issue.一切都很顺利,除了一个小问题,由于 mkdir 文件权限问题,我无法创建文件夹和上传文件。 How can we give permissions when uploading files and create folders?上传文件和创建文件夹时如何授予权限?

Your help can save me a lot of time.你的帮助可以为我节省很多时间。

You can configure your runtime_config by adding the skip_lockdown_document_root in app.yaml .您可以通过在app.yaml中添加skip_lockdown_document_root配置您的runtime_config

By default, the runtime will set a strict read-only permission on all the files and directories under the document_root directory.默认情况下,运行时会对 document_root 目录下的所有文件和目录设置严格的只读权限。 When set to true, the runtime will skip changing the permission.设置为 true 时,运行时将跳过更改权限。

runtime_config:
  document_root: .
  skip_lockdown_document_root: true

I still recommended to use Cloud Storage for storing or serving file on a serverless platform.我仍然建议使用Cloud Storage在无服务器平台上存储或提供文件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM