This is a basic example of a shrun setup. It provides a bare-bones command line tool testshrun
, and a set of corresponding shrun specs which test that tool.
Note: for many users
sudo
will be necessary to run shrun commands as it relies on Docker which tends to be installed as root.
clone
git clone git@github.com:rylandg/shrun-basic-demo.git
cd shrun-basic-demo
install dependency (shrun)
npm install
#or
yarn install
build demo docker image
npm run build
or with sudo
sudo npm run build
This will create a docker image that contains the basic testshrun
command line tool.
If you're interested in using alpine instead of ubuntu, run:
sudo npm run build-alpine
run shrun
npm run spec
or with sudo
sudo -E npm run spec
-
A very minimal command line tool (named
testshrun
). This tool makes it possible to write customshrun
test specs. -
Two package.json commands (
build
&&spec
) which simplify the process of building the default shrun image, and running tests. -
A
specs/demo.yml
spec test file which showcases the basic functionality of shrun.
If you're interested in looking at the default shrun docker files, they are available here. Feel free to copy it locally and modify it to fit your needs.