Skip to content

Instantly share code, notes, and snippets.

@mathieu-benoit
Created May 2, 2026 20:50
Show Gist options
  • Select an option

  • Save mathieu-benoit/bef1036814fcf0d4a04a65c5ef489a71 to your computer and use it in GitHub Desktop.

Select an option

Save mathieu-benoit/bef1036814fcf0d4a04a65c5ef489a71 to your computer and use it in GitHub Desktop.
Demo Score + Microcks
#!/bin/bash
# setup
if [ ! -f demo-magic.sh ]; then
curl -LO https://github.com/paxtonhare/demo-magic/raw/master/demo-magic.sh
fi
. demo-magic.sh -d #-n
clear
# Demo setup
alias k=kubectl
make k8s-down
make compose-down
rm -rf .score-compose
rm -rf .score-k8s
clear
# Demo #0
pe "echo \"Demo #0 - score-k8s\""
pe "make k8s-up"
pe "kubectl get all"
pe "kubectl get pods"
pe "echo $(score-k8s resources get-outputs dns.default#ingress.dns --format 'http://{{ .host }}')"
pe "echo \"Demo #0 - score-compose\""
pe "make compose-up"
pe "docker ps"
pe "echo http://localhost:8080"
#!/bin/bash
# setup
if [ ! -f demo-magic.sh ]; then
curl -LO https://github.com/paxtonhare/demo-magic/raw/master/demo-magic.sh
fi
. demo-magic.sh -d #-n
clear
# Demo #1
pe "echo \"Demo #1 - score-k8s\""
pe "code trade-service/score.yaml"
pe "code -g Makefile:72"
pe "code manifests.yaml"
pe "kubectl get all"
pe "kubectl get pods"
pe "score-k8s resources get-outputs dns.default#ingress.dns --format 'http://{{ .host }}'"
# Demo #2
pe "echo \"Demo #2 - score-compose\""
clear
pe "code trade-service/score.yaml"
pe "code -g Makefile:21"
pe "make compose-up"
pe "code compose.yaml"
pe "docker ps"
pe "echo http://localhost:8080"
#!/bin/bash
# setup
if [ ! -f demo-magic.sh ]; then
curl -LO https://github.com/paxtonhare/demo-magic/raw/master/demo-magic.sh
fi
. demo-magic.sh -d #-n
clear
# Demo setup
make compose-down
rm -rf .score-compose
clear
# Demo #3
pe "echo \"Demo #3 - score-compose (Mocks)\""
pe "code trade-service/score.yaml"
pe "code -g Makefile:47"
pe "make compose-mock-up"
pe "code compose.yaml"
pe "docker ps"
pe "echo http://localhost:8080"
pe "echo http://localhost:9090"
#!/bin/bash
# setup
if [ ! -f demo-magic.sh ]; then
curl -LO https://github.com/paxtonhare/demo-magic/raw/master/demo-magic.sh
fi
. demo-magic.sh -d #-n
clear
# Demo setup
alias k=kubectl
make k8s-down
rm -rf .score-k8s
clear
# Demo #4
clear
pe "echo \"Demo #4 - score-k8s (Mocks)\""
pe "code trade-service/score.yaml"
pe "code -g Makefile:88"
pe "make k8s-mock-up"
pe "code manifests.yaml"
pe "kubectl get all"
pe "kubectl get pods"
pe "score-k8s resources get-outputs dns.default#ingress.dns --format 'http://{{ .host }}'"
pe "echo https://microcks.127.0.0.1.nip.io/"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment