grails cloud-hosting recommendation [closed]
Asked Answered
B

2

7

I'm looking for cloud-hosting for a Grails app. In the past, I've tried several including CloudFoundry, JElastic, AppFog, but could never successfully deploy the app. The app needs:

  • MySQL database
  • File system access in order to store the Searchable plugin index files and images uploaded by users

I'll only be using this site for QA, so am not concerned about performance. Obviously I'd like it to be as simple as possible to deploy the app, and I'd like to pay as little as possible for the hosting.

I've already tried using the CloudFoundry Grails plugin to deploy to CloudFoundry, but without any success.

Bernhard answered 4/5, 2013 at 11:10 Comment(6)
I have had good experience with cloudbees and grails but not sure about their file system accessibility policy.Carnarvon
Apparently CloudBees provide temporary/ephemeral filesystem access, which would be sufficient for my app in QA developer.cloudbees.com/bin/view/RUN/File+system+accessTrudge
I really don't understand why this question is considered unconstuctive. I've asked a specific programming-related question "where can I host a Grails app in the cloud with file system access". I've demonstrated that I've already done some research into the topic, what's the problem....?Trudge
Just want to pay your attention at this article: jelastic.com/docs/jelastic-grails-deploy With this instruction it seems pretty easy.Orchestra
@Orchestra thanks, looks good, but it's not clear whether file system access is availableTrudge
Indeed there is an access available: jelastic.com/docs/application-configurationOrchestra
G
1

I have successfully hosted Grails based websites on Amazon EC2. To reduce the cost, I used small reserved instance. I think It's ok to use Amazon EC2 AMI for temporary files such as searchable index files since you can always re-index if AMI crashes.

To store user images, I used Amazon S3 using Grails AWS SDK plugin (http://grails.org/plugin/aws-sdk). It is very easy to upload files to S3 using Amazon SDK http://blanq.github.io/grails-aws/1.2.12.1/index.html -

To Upload a file with public read permissions.

amazonWebService.s3.putObject(new PutObjectRequest('some-grails-bucket', 
'somePath/someKey.jpg', new  File('/Users/ben/Desktop/photo.jpg')).withCannedAcl( CannedAccessControlList.PublicRead ) )

Download a file.

amazonWebService.s3.getObject(new GetObjectRequest('some-grails-bucket', 
'somePath/someKey.jpg'), new File('/Users/ben/Downloads/photo.jpg'))

Delete a file.

amazonWebService.s3.deleteObject('some-grails-bucket', 'somePath/someKey.jpg')

I hope this helps.

Gherardo answered 4/5, 2013 at 23:48 Comment(0)
S
0

I know it's not an ideal solution, but you could use mongodb's gridfs to store your files rather than the file system. Cloudfoundry supports mongodb, as I'm sure you know.

This doesn't help with your searchable plugin index though.

Smile answered 4/5, 2013 at 20:28 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.