Working on this repo requires Ruby, Bundler, nodejs with npm and grunt-cli.
To Deploy you will need to install Awscli, which you can easily do with homebrew
Update: I recommend instead using the s3_website tool (https://github.com/laurilehmijoki/s3_website), to manage and deploy to s3.
- Clone this repo
- Ensure Ruby is installed
- Ensure Bundler is installer
- Ensure NodeJS and NPM are installed
- Ensure the grunt-cli node module is installed globally
- Run
npm install
- Ensure [s3_website] is install (gem install s3_website)
- To build the site run
grunt
-
grunt test
Runsjscs
andjshint
checks on theGruntfile
itself, and all configured tasks inbuild/tasks
-
grunt dev
Serves the content of_site
on localhost:4000 then runs both awatch
task to compile stylus files ANDjekyll serve
so all site modifications are automatically pushed to_site
-
grunt
The default task runstest
,css
, andjekyll:build
tasks outputting the static site into_site
-
alternately, run
bundle exec jekyll serve -w
, which will deploy as well to http://localhost:4000. The -w will watch and auto-rebuild as you edit files.n
Create an AWS account if you don’t already have one. Login to the management console and create some S3 buckets!
- YOURDOMAINNAME
- Static site hosting will need to be enabled
- WWW.YOURDOMAINNAME
- This will also have static site hosting enabled but will redirect to the YOURDOMAINNAME bucket
Update the s3_website.yml file with your id, key and bucket name: s3_id: YOUR_AWS_S3_ACCESS_KEY_ID s3_secret: YOUR_AWS_S3_SECRET_ACCESS_KEY s3_bucket: your.blog.bucket.com
when ready to publish, run:
s3_website push
you can run s3_website push --dry-run
to test it out first.
there' lots of configuration options, including CloudFront integration documents at https://github.com/laurilehmijoki/s3_website