Skip to content
master
Switch branches/tags
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
css
 
 
 
 
img
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

StackShare

jona.io

Personal Website, build with Jekyll. See the components used on this Stack on Stackshare.

Development

Install Jekyll and it's prerequisites if you don't have them installed yet:

gem install bundler jekyll github-pages
bundle install

Serve the website and test your changes locally:

cd jona.io
bundle exec jekyll serve

If you want to test outside your local machine (with your phone for example) add the host parameter:

cd jona.io
bundle exec jekyll serve --host 0.0.0.0

Functions

This website is a static site but has a few dynamic components. Javascript retrieves specific data from custom API's to fill certain area's of the website. Google Cloud functions are exposed as REST API's. These functions are deployed with gcloud and can be found in the _functions directory.

First you will need to install the gcloud sdk. See the quickstart tutorials for your specific environment: https://cloud.google.com/sdk/docs/quickstarts.

The functions need a few environment variables to be set which are defined in the env.yml configuration file. Copy the example env.yml.example file to env.yml and add the required values.

To deploy a function go to the _functions directory and run the ./deploy.sh script to deploy one specific or all functions:

./deploy all
./deploy spotify-nowplaying

You can find other gcloud functions deploy flags here: https://cloud.google.com/sdk/gcloud/reference/functions/deploy if you want to change the behaviour of the deployment.