Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update demo scripts #1

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 8 additions & 16 deletions hack/scripts/demo-script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,24 @@

trap "trap - SIGTERM && kill -- -$$" SIGINT SIGTERM EXIT
# Welcome to the catalogd demo
kind delete cluster
kind create cluster
kubectl cluster-info --context kind-kind
sleep 10
# install catalogd on the cluster
# could also `make install` in repo
kubectl apply -f https://github.com/operator-framework/catalogd/releases/latest/download/catalogd.yaml
kubectl wait --for=condition=Available -n olmv1-system deploy/catalogd-controller-manager --timeout=60s
sleep 10
make run
# inspect crds (catalog)
kubectl get crds -A

# create a catalog
kubectl apply -f config/samples/core_v1alpha1_catalog.yaml
kubectl apply -f config/samples/core_v1alpha1_clustercatalog.yaml
# shows catalog-sample
kubectl get catalog -A
kubectl get clustercatalog -A
# waiting for catalog to report ready status
time kubectl wait --for=condition=Serving catalog/operatorhubio --timeout=1m
time kubectl wait --for=condition=Serving clustercatalog/operatorhubio --timeout=1m

# port forward the catalogd-catalogserver service to interact with the HTTP server serving catalog contents
(kubectl -n olmv1-system port-forward svc/catalogd-catalogserver 8080:80)&
(kubectl -n olmv1-system port-forward svc/catalogd-catalogserver 8080:443)&

# check what 'packages' are available in this catalog
curl http://localhost:8080/catalogs/operatorhubio/all.json | jq -s '.[] | select(.schema == "olm.package") | .name'
curl -k https://localhost:8080/catalogs/operatorhubio/all.json | jq -s '.[] | select(.schema == "olm.package") | .name'
# check what channels are included in the wavefront package
curl http://localhost:8080/catalogs/operatorhubio/all.json | jq -s '.[] | select(.schema == "olm.channel") | select(.package == "wavefront") | .name'
curl -k https://localhost:8080/catalogs/operatorhubio/all.json | jq -s '.[] | select(.schema == "olm.channel") | select(.package == "wavefront") | .name'
# check what bundles are included in the wavefront package
curl http://localhost:8080/catalogs/operatorhubio/all.json | jq -s '.[] | select(.schema == "olm.bundle") | select(.package == "wavefront") | .name'
curl -k https://localhost:8080/catalogs/operatorhubio/all.json | jq -s '.[] | select(.schema == "olm.bundle") | select(.package == "wavefront") | .name'

2 changes: 1 addition & 1 deletion hack/scripts/gzip-demo-script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ trap "trap - SIGTERM && kill -- -$$" SIGINT SIGTERM EXIT
make run

# create a clustercatalog
kubectl apply -f $HOME/devel/tmp/operatorhubio-clustercatalog.yaml
kubectl apply -f config/samples/core_v1alpha1_clustercatalog.yaml
# shows catalog
kubectl get clustercatalog -A
# waiting for clustercatalog to report ready status
Expand Down
Loading