This image builds sites using Jekyll.
This example is using the OpenShift Applier to build and deploy Jekyll. As a result you'll need to have ansible installed.
The openshift-applier will create the following OpenShift objects:
- A Project named
s2i-jekyll
- Three ImageStreams named
ruby
,jekyll-builder
andopenshift-playbooks
(see .openshift/templates/imagestreams/template.yml. - Two BuildConfigs named
jekyll-builder
andopenshift-playbooks
(see .openshift/templates/builds/docker-template.yml and .openshift/templates/builds/source-template.yml) - A Service named
openshift-playbooks
(see .openshift/templates/deployments/template.yml) - A Route named
openshift-playbooks
(see .openshift/templates/deployments/template.yml) - A DeploymentConfig named
openshift-playbooks
(see .openshift/templates/deployments/template.yml)
- Clone this repository:
git clone https://github.com/redhat-cop/containers-quickstarts
cd containers-quickstarts/build-s2i-jekyll
- Run
ansible-galaxy install -r requirements.yml --roles-path=roles
- Login to Openshift:
oc login -u <username> https://master.example.com:8443
- Run openshift-applier:
ansible-playbook -i inventory/hosts roles/openshift-applier/playbooks/openshift-cluster-seed.yml
Now we can oc get routes
to get the hostname of the route that was just created, or click the link in the OpenShift Web Console, and test our newly published jekyll site.
NOTE: This image is not intended to be used to serve the content provided by jekyll. It can do so, but is meant for testing purposes only. For hosting the html site produced by this image, consider using the s2i-httpd image, or for someting even more light weight, check out our Go Web Server.