1

I am running CodeIgniter PHP Framework on Google APP Engine using flex environment. Everything is going well except for one small issue, I unable to create folder and upload files because of mkdir file permission issue. How can we give permissions when uploading files and create folders?

Your help can save me a lot of time.

JM Gelilio
  • 3,482
  • 1
  • 11
  • 23
MMuzammilQ
  • 257
  • 5
  • 17
  • 1
    App Engine standard (!) has a memory-based file system mounted at `/tmp` but (!) I'm unsure whether flexible runtimes provides volume mounts like this. You may want to try. However, these are per-instance and not persistent. You may want to consider using Cloud Storage to persist file content but Cloud Storage doesn't give you a mountable file system either and so work is needed. – DazWilkin Jan 19 '21 at 03:27

1 Answers1

3

You can configure your runtime_config by adding the skip_lockdown_document_root in app.yaml.

By default, the runtime will set a strict read-only permission on all the files and directories under the document_root directory. When set to true, the runtime will skip changing the permission.

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.

JM Gelilio
  • 3,482
  • 1
  • 11
  • 23