menu

ZEIT

Our mission is to make cloud computing as easy and accessible as mobile computing. You can find our Next.js community here.

Channels
Team

/tmp directory available at lambda runtime on now v2?

March 20, 2019 at 8:18am

/tmp directory available at lambda runtime on now v2?

March 20, 2019 at 8:18am

AWS lambdas can write files to a temporary directory (scratch disk). Is this possible with now v2 as the docs indicate it was possible with now v1. The goal is to allow media uploads to work in WordPress by moving assets to S3 after the upload completes. Right now an error message appears which says the /tmp directory or its parent cannot be written to.


March 20, 2019 at 11:43am

You should be able to write to /tmp. Can you give me the full logs?

  • reply
  • like
  • reply
  • like

There's nothing in the logs that helps unfortunately. I'm not sure if this is normal or if the php error log isn't correctly output here?

  • reply
  • like

I've just tried deploying again and I'm not seeing anything in the logs whatsoever now??

  • reply
  • like

Can you make a public deployment? 'now --public'

  • reply
  • like

I can't repro this with a node deployment...

  • reply
  • like

I'll make a public deployment asap

  • reply
  • like

It's the now/wordpress builder

  • reply
  • like

I've followed the documentation that's about to be merged

  • reply
  • like

Not sure if relevant but I'm deploying another route alongside that's a node app

  • reply
  • like

That is the beauty of Now 2.0, we can isolate things and mix but problems are isolated! So no, the node deployment is not relevant for the issue

  • reply
  • like

March 20, 2019 at 8:08pm

Having looked into this further its a WordPress issue https://codex.wordpress.org/Editing_wp-config.php#Moving_uploads_folder

  • reply
  • like

Glad you found it.

  • reply
  • like