Comments (5)
Ok
this what I did to make it work:
in config/plugins/wordpress/wordpress-s3uploads.php
change this:
define('S3_UPLOADS_KEY', $env['user']);
define('S3_UPLOADS_SECRET', $env['pass']);
define('S3_UPLOADS_REGION', str_replace(array('s3-', '.amazonaws.com'), array('', ''), $env['host']));
define('S3_UPLOADS_BUCKET', ltrim($env['path'], '/'));
in to:
define( 'S3_UPLOADS_BUCKET', 'my-bucket-name' );
define( 'S3_UPLOADS_KEY', 'my-aws-key' );
define( 'S3_UPLOADS_SECRET', 'my-aws-secret' );
define( 'S3_UPLOADS_REGION', 'my-s3-region );
and it work
from wordpress-heroku.
You'r right, since you can't write to the heroku filesystem you can't write to that file - but we can still use all the other features of the plugin for security.
But the error you get has no relation to the issue you have with uploading media files. If you want to upload media files, than you need to provide heroku with an external storage.
Check out the Persistent Storage (Optional)
Step in the Deployment - Heroku - Manual
instructions in https://github.com/PhilippHeuer/wordpress-heroku/wiki/Deployment to use Amazon S3 as storage.
from wordpress-heroku.
I actually do have S3 set up following those instructions.
I was assuming that maybe I wasn't even getting to the point of looking up the S3_AWS_URL because I was only getting the above error in the Papertrail logs.
I am using Bucketeer. I believe I am constructing the S3_AWS_URL the same way you are using the bucketeer variables here:
https://github.com/PhilippHeuer/wordpress-heroku/blob/9b8ef96ca8a77bf4826f32bbfc1473815c823f50/config/plugins/heroku/heroku-bucketeer.php
Except where you use s3.amazonaws.com, I am using s3-BUCKETEER_AWS_REGION-amazonaws.com.
I have tried populating the AWS_S3_URL manually, and I have tried removing it and letting the above code construct the URL (which I believe will not work since my bucket is in us-east-1).
On a whim, I also tried encoding the '/' characters in my SECRET_ACCESS_KEY to %2F, but that didn't make a difference.
Also, I am getting this error in the WordPress UI
â1121f00.jpgâ has failed to upload.
The uploaded file could not be moved to uploads/2017/11.
This suggests that it is still trying to write locally, correct?
from wordpress-heroku.
To clarify about the heroku filesystem, you can write to it locally, but the data is lost after a short while.
Your uploading issue occurs when you try to store the file locally, before it is uploaded to the external storage. I tried to reproduce your issue but it didn't happen to me when i followed the instructions in the wiki to deploy a new instance.
Did you modify anything else?
from wordpress-heroku.
Hi,
Have same isssu
even tryed to change to:
putenv(sprintf('AWS_S3_URL=s3://%s:%s@%s/%s', $env['user'], getenv("BUCKETEER_AWS_ACCESS_KEY_ID"), getenv("BUCKETEER_AWS_SECRET_ACCESS_KEY"), getenv("BUCKETEER_BUCKET_REGIONS"), getenv("BUCKETEER_BUCKET_NAME")));
from wordpress-heroku.
Related Issues (20)
- Wordfence could not get an API key from the Wordfence scanning servers when it activated HOT 1
- Wp-admin password HOT 2
- The uploaded file could not be moved to uploads HOT 12
- Blank browser page on local machine for brand new WP site HOT 1
- Error when connecting to local WP Admin: Invalid request (Unsupported SSL request) HOT 4
- Can't run wp-cli server locally HOT 2
- Setting up Multisite HOT 6
- Some key can't parse correctly AWS_S3_URL HOT 1
- custom domain name HOT 5
- More languages [SOLVED] HOT 4
- Add others Language to Wordpress HOT 1
- DB error on local environment construction
- how to upload my own theme & plugin not exist as public ? HOT 1
- Adsense - Failed to load resource: net::ERR_CONNECTION_REFUSED
- Database caching help needed
- Image sizes not respected HOT 1
- When trying to Deoply to Heroku - the configuration of SendGrid add-on fails HOT 1
- Heroku teams deploy fails
- Any plans to upgrade dependency versions? HOT 6
- How to add my plugins locally then push to heroku ? I need a simple 1,2,3 steps guide
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
ð Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ððð
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google â€ïž Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wordpress-heroku.