modifiedcontent

Has anyone installed Processwire on Amazon EC2?

Recommended Posts

alan    364
11 hours ago, LostKobrakai said:

not as plain replacement for a single VPS elsewhere (which really has no great benefit to be run on amazon or not)

I've assumed that I can use Amazon in place of a traditional VPS, such as Servint (who I like), for a significant saving. Maybe I'm wrong in that assumption..?

To test that assumption and learn I've been working with Amazon EC2 to see if I can teach myself how to host multiple sites. So far so good.

  • Like 2

Share this post


Link to post
Share on other sites
Robin S    2,525
3 hours ago, alan said:

To test that assumption and learn I've been working with Amazon EC2 to see if I can teach myself how to host multiple sites. So far so good.

A write-up/tutorial would be much appreciated when you're ready! :)

  • Like 2

Share this post


Link to post
Share on other sites
LostKobrakai    4,313
10 hours ago, alan said:

I've assumed that I can use Amazon in place of a traditional VPS

You absolutely can, but that's not why EC2 is so powerful and it's by no means suddenly more scaleable than a VPS elsewhere. That's what people are often missing. The scaleablity praise for amazon comes from things like autoscaling, which dynamically adds new EC2 instances or destroys unused ones, which has the same problems and hurdles you've had on heroku as well (except on aws you have to do the setup on your own as well). And for the complexity of amazons security management and other things involved in AWS it's probably better for unexperienced people to just go with digitalocean/linode for single instance VPS, because the savings in money on AWS are probably counteracted by the time saved not setting up EC2, but simple clicking a few buttons somewhere else.

  • Like 2

Share this post


Link to post
Share on other sites
cstevensjr    1,378
4 hours ago, LostKobrakai said:

You absolutely can, but that's not why EC2 is so powerful and it's by no means suddenly more scaleable than a VPS elsewhere. That's what people are often missing. The scaleablity praise for amazon comes from things like autoscaling, which dynamically adds new EC2 instances or destroys unused ones, which has the same problems and hurdles you've had on heroku as well (except on aws you have to do the setup on your own as well). And for the complexity of amazons security management and other things involved in AWS it's probably better for unexperienced people to just go with digitalocean/linode for single instance VPS, because the savings in money on AWS are probably counteracted by the time saved not setting up EC2, but simple clicking a few buttons somewhere else.

I agree with all that you are saying, however I also think that people want more choices.  It may be complex setting things up, but what does it hurt to find out how to make it work?  I know I am interested in learning how to make the different AWS services work with ProcessWIre.

  • Like 1

Share this post


Link to post
Share on other sites
alan    364
14 hours ago, Robin S said:

A write-up/tutorial would be much appreciated when you're ready! :)

I plan to ^_^

I am not there yet, but I have PW working and am just hunting down a bug, if that proves trivial and other tests work OK then I will certainly write it up.

Thanks @LostKobrakai for your comments, you are clearly way ahead of me in this department—it's very helpful to hear from someone with your knowledge. Re:

7 hours ago, LostKobrakai said:

with digitalocean/linode for single instance VPS

I did look at both of these a little, but it seemed they were principally aimed at people who routinely take bare Linux and get LAMP running, I may be wrong. But based on that assumption and guessing the docs on Amazon were perhaps going to encompass me (someone who'd heard of `yum` but hardly ever used it) I returned to Amazon.

I tried Amazon Lightsail but fell off the process when it looked like I had to use the bitnami LAMP bundle (see below), or use Amazon tuts written for EC2, not Lightsail, and using those with Lightsail did not work and I was on too thin knowledge-ice to keep going. So I simply decided to try EC2 + the Amazon tuts written for getting EC2 LAMP, and so far, so good.

Re:

3 hours ago, cstevensjr said:

but that's not why EC2 is so powerful and it's by no means suddenly more scaleable than a VPS elsewhere

Thanks for noting this, I did understand that I was almost 'misusing' EC2 by looking to simply make a tiny VPS in the cloud and almost certainly not using any of the amazing features AWS offers, but I am not coming to AWS for the reasons most would and it's helpful to note that as I don't want to mislead :).  I'm coming to AWS from a weird angle, where I want to make a solid, modest cloud VPS equivalent, where I can host 10 sites or so, needing no elastic redundancy or power-up capabilities BUT wanting to take advantage of paying for use (low) rather than a flat monthly fee that I pay a traditional hoster, where my low consumption of resources is not reflected in my fixed monthly bill. I should have stated that earlier ;)

Aside

I was put off when looking at Amazon + bitnami by reviews of the bitnami LAMP bundle. Conversely I have so far been left confident about the Amazon Linux distro and the tutorial for getting LAMP up. It's not been quite as simple as following a tutorial, but I've not had to search too far to keep proceeding and I feel less intimidated logging into AWS than I used to, so that's one take away at least ;)

One of the review that made me stop looking at Amazon + bitnami:

Quote

 

This image is really awful! 
1) All applications are installed in /opt/bitnami instead of their default locations. If an expert, like me, tries to work with it, he has to learn all configs from scretch. 
2) All applications are highly coupled. In order to change mysql data location I had to edit 15!!! files. 
3) It's not possible to restart single application, as all of them are installed in a bundle. 
4) There's no even restart for the bundle service. 

The result: 2 work hours lost + moved to other image 

Probably it was the worst experience I ever had with preinstalled images.

Source

 

I was also concerned that I may end up paying bitnami for LAMP (per month?) plus Amazon and yet one of my motivations for this exercise was trying to lower my VPS costs (which due to currency changes is about 50% up on what I used to pay).

  • Like 1

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By Karl_T
      Short question: is it possible that Processwire uses AWS S3 with s3fs as a remote file system(mount to asset folder)? Please advise anything that have to be take care of.
       
      Background:
      I am currently trying to make Processwire running inside AWS Beanstalk as I want to take advantages of the auto scaling function that my client wanted.
      I have found a discussion here: 
       
      By reading this and the link inside, I realize that to use the auto scaling I need to configure my web server to be stateless. So, I was looking for a method that can serve the purpose and then I found s3fs.  s3fs is a FUSE filesystem that allows you to mount an Amazon S3 bucket as a local filesystem, quoted from their github. I guess that mounting s3 bucket using s3fs to the asset folder should be the right thing to do.
      My site needs many image upload as it is an e-commerce site using padloper while the admin always using the local file system for images. I have thought of using modules like AmazonS3Cloudfront or FieldtypeFileS3. It seems like those modules are not support my use case. s3fs suits better and more simple. One of my concerns is that I am not sure can the URL of the images can be generated by the default API like $image->url correctly. 
      Before implementing this, I would like to ask the advise from anyone having implemented this with processwire as I am new to AWS. Is it possible? Any better alternatives?
      I think if not implementing auto scaling, it is also good to separate asset away in some cases, like reducing requests. Thank you for your reading. 
    • By fbg13
      FieldtypeFileS3
      https://github.com/f-b-g-m/FieldtypeFileS3
      The module extends the default FieldtypeFile and InputfieldFile modules and adds few extra methods.
      For the most part it behaves just like the default files modules, the biggest difference is how you get the file's url. Instead of using $page->fieldname->eq(0)->url you use $page->fieldname->eq(0)->s3url(). Files are not stored locally, they are deleted when the page is saved, if page saving is ommited the file remains on the local server until the page is saved. Another difference is the file size, the default module get the file size directly from the local file, while here it's stored in the database.
      There is an option to store the files locally, its intented in case one wants to stop using S3 and change back to local storage. What it does is it changes the s3url() method to serve files from local server instead of S3, disables uploading to S3 and disables local file deletion on page save. It does not tranfer files from S3 to local server, that can be done with the aws-cli's through the sync function. Files stored on S3 have the same structure as they would have on the local server.
      -------------------------------------------------------- --------------------------------------------------------
      Been struggling with this for quite a while, but i think i finally managed to make it work/behave the way i wanted.

      All feedback is welcome!
    • By hellomoto
      I have web hosting with the following .htaccess en root, to point it to a subdirectory "audino.us", wherein I have PW installed:
      RewriteEngine on RewriteCond %{HTTP_HOST} ^(www.)?something.com$ RewriteCond %{REQUEST_URI} !^/something.com/ RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ /audino.us/$1 RewriteCond %{HTTP_HOST} ^(www.)?something.com$ RewriteRule ^(/)?$ something.com/index.php [L] RewriteCond %{HTTP_HOST} ^(www.)?something.com$ RewriteRule ^(/)?$ something.com [L] However when I go to audino.us/pw to access the admin, it becomes audino.us/audino.us/pw, and doesn't allow me to log in. How do I render the above to be recursive (?), i.e., to apply to all subordinate URLs? Is this to be done within the .htaccess in /audino.us, or in the root .htaccess above? Please help, I can't log in. Thanks much.
    • By sudodo

      777 seems excessive - is there something that I'm missing here?
      This is a print out of the /site content;
      ```
      total 28
      drwxrwxr-x 6 geot geot 4096 Sep  9 13:30 .
      drwxrwxr-x 8 geot geot 4096 Sep  9 13:17 ..
      drwxrwxr-x 2 geot geot 4096 Sep  6 10:10 assets
      -rwxrwxrwx 1 geot geot 1548 Sep  6 10:10 config.php
      drwxrwxr-x 3 geot geot 4096 Sep  6 10:10 install
      drwxrwxr-x 2 geot geot 4096 Sep  6 10:10 modules
      drwxrwxr-x 5 geot geot 4096 Sep  6 10:10 templates
      ```
      I'm sure that I shouldn't have to have permissions so high, but I'm pretty new
      to this.

      Here's a shot of the setup that I'm currently going through;

      http://imgur.com/a/WkhAX

      You can see that the error (for site/config.php) is no longer there with these
      permissions, but they still 'feel' wrong.
      Thanks
       
    • By totoff
      Hi Forum,
      we moved an installation from the live server to localhost for further development. Unfortunately now PW doesn't find files in the /templates/ directory anymore (e.g. css, js and so on). Functions testing for existing files abort with an error and the console throws 404 for the files in question.
      Two developers have checked (so far several times):
      site/config.php $config->httpHosts .htaccess file permissions on /templates/ and all subdirectories (set to 777 just to be on the safe side) our own php functions Our version is 3.0.22 devns.
      We are running out of ideas. Any help is appreciated. Thanks.