merbin2012 / sharex

Automatically exported from code.google.com/p/sharex
0 stars 1 forks source link

S3 Custom Hostname/DreamObjects #569

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
You fulfilled my S3 request to issue 440. I appreciate that.
I would like to request adding an option to the page to change the hostname.
This would allow people to use any S3 type service that's not specifically 
Amazon's, such as DreamHost's DreamObjects. 

It uses the same API, so the only change that would be needed is the hostname 
(which would be objects.dreamhost.com for DreamObjects). 

I would, perhaps, add a checkbox above "Endpoint" for "Custom Hostname" that 
when checked, enables a text field allowing users to enter their own hostname. 
This would then make "endpoint" optional (if it isn't already)

Alternatively, could we at least get a DreamObjects tab? It's quickly picking 
up as a much cheaper alternative to Amazon S3. I'm sure DreamHost would also 
promote ShareX if you directly supported their service, as they do with any 
software that does.

I can provide you with a DreamObjects bucket and key if you were willing to 
integrate one or the other. If you did it the first way, you could support 
massive amounts of alternative S3 services that use the same API as Amazon S3. 
Otherwise, if we could at least get DreamObject support we'd be incredibly 
thankful. 

Original issue reported on code.google.com by nathania...@fatedproductions.com on 3 May 2014 at 11:05

GoogleCodeExporter commented 9 years ago
You can change endpoint from config file (UploadersConfig.json):

"Endpoint": "https://s3-eu-west-1.amazonaws.com/"

It must be configurable from ui too.

Original comment by flexy...@gmail.com on 3 May 2014 at 11:10

GoogleCodeExporter commented 9 years ago
Okay, I modified UploadersConfig.json to look like this:

"AmazonS3Settings": {
    "AccessKeyID": "DreamObjectsAcessKey",
    "SecretAccessKey": "MySecretKey",
    "UseReducedRedundancyStorage": false,
    "UseCustomCNAME": true,
    "ObjectPrefix": "sharex",
    "Bucket": "mybucketname",
    "Endpoint": "https://objects.dreamhost.com/"
  },

I get an error when trying to capture a screenshot now. It looks like it's 
still trying to communicate with Amazon itself.

<Error><Code>InvalidAccessKeyId</Code><Message>The AWS Access Key Id you 
provided does not exist in our 
records.</Message><RequestId>202551DF6D83761A</RequestId><HostId>+rgQe82OO7wg7KZ
U3A1IZGiApGElrjKYIGnu9qgaz9+Ow2APCahQl8iP6j/uCF24</HostId><AWSAccessKeyId>2-I0eY
ScJ0pzITaA45GJ</AWSAccessKeyId></Error>

Is there anything I'm missing? Is there another file where I can edit what host 
it connects to to push files? As long as I can get it communicating with 
DreamObject's server, the API is the same and it will handle everything from 
there.

As an alternative, we've been using a custom uploader. ShareX calls a script on 
my site which then pushes the data to DreamObjects. The script is viewable 
here: 
http://pastebin.com/zGvPxmAX

The downside is that uploads are limited to the max PHP upload of the server of 
my site. It would be ideal to be able to upload directly to DreamObjects and 
have a much higher max upload file size of 5 GB.

Original comment by nathania...@fatedproductions.com on 3 May 2014 at 11:37

GoogleCodeExporter commented 9 years ago
Hello,

I wrote the S3 integration originally - would you be able to provide a 
DreamObjects access key and secret for testing?

My email address is sharexs3issues [at] alanedwardes [dot] [com], or I'm 
alanedwardes on Steam.

Cheers,

Alan.

Original comment by a...@alanedwardes.com on 4 May 2014 at 2:09

GoogleCodeExporter commented 9 years ago
fixed by Alan.

Original comment by flexy...@gmail.com on 5 May 2014 at 10:04