#!/bin/sh

DISTRO="`grep ^ID= /etc/*-release | cut -d'"' -f2`"

cat <<EOF
This is a S2I ruby-${RUBY_VERSION} ${DISTRO} base image:

To use it in Openshift, run:
oc new-app ruby:${RUBY_VERSION}~https://github.com/sclorg/s2i-ruby-container.git --context-dir=${RUBY_VERSION}/test/puma-test-app/

You can then run the resulting image via:
$ oc get pods
$ oc exec <pod> -- curl 127.0.0.1:8080

Alternatively, to run the image directly using podman or docker, or how to use it as a parent image in a Dockerfile, see documentation at

https://github.com/sclorg/s2i-ruby-container/blob/master/${RUBY_VERSION}/README.md
EOF