ryanmurakami/hbfl

Stylesheets missing when uploading to AWS

Closed this issue · 3 comments

Hello,

When using the create-ec2-instance.js script to deploy this project to an ec2 instance, the UserData script is pulling the code from master instead of main.

This causes the stylesheets and favicon to comeback as a 404.
Please update the UserData script so that it points to the main branch when uploading to ec2.

Ah, I'm a dork.
This has already been discussed in the AWS Developer: Designing and Developing course on Pluralsight.

From Jose Johnson
The affected file: package.json

// from
"css-minimizer-webpack-plugin": "1.1.5",
// to
"css-minimizer-webpack-plugin": "1.2.0",

Hi Ryan,
I'm a bit new to do this, but, moving along, I'm in module 3, last step of creating the instance, I was able to run the create-ec2-instance.js script successfully. However, something's not right, as I'm also getting the 404 when trying to hit my ec2 instance. Also, I logged into my instance, but I don't see the code installed on the instance, here's the steps I did:

  1. cloned the repo
  2. made create-ec2-instance.js changes
  3. updated the package.json plugin from 1.1.5 to 1.2.0
  4. ran "npm install" at project root
  5. ran create-ec2-instance.js from scripts/module_02 directory
  6. script ran without error, I see ownerId and reservationId
  7. went to ec2 via the console to get public ip
  8. entered http://54.183.4.5:3000 into browser
  9. getting this in dev tools: GET http://54.183.4.5:3000/public/stylesheet.css net::ERR_ABORTED 404 (Not Found)
  10. logged into instance via SSH and I do not see anything in the /home/ec2-user directory

I appreciate any help.

Thanks,
Stan

Thanks @erw444 and @smrivera0725 for reporting this. I've updated the repository to the current version of css-minimizer-webpack-plugin.