diff --git a/dev-sandbox/Containerfile b/dev-sandbox/Containerfile new file mode 100644 index 0000000..75826d2 --- /dev/null +++ b/dev-sandbox/Containerfile @@ -0,0 +1,9 @@ +FROM registry.access.redhat.com/ubi9/ubi + +ENV RHDH_BASE_URL=localhost + +RUN yum install -y jq && yum clean all + +COPY mvp.sh /tmp/mvp.sh + +CMD /tmp/mvp.sh diff --git a/dev-sandbox/mvp.sh b/dev-sandbox/mvp.sh new file mode 100755 index 0000000..a99f64c --- /dev/null +++ b/dev-sandbox/mvp.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +RHDH_BASE_URL=${RHDH_BASE_URL:-localhost} + +curl="curl -sSL --insecure" + +token=$($curl "${RHDH_BASE_URL}/api/auth/guest/refresh" | jq -r '.backstageIdentity.token') + +$curl -H "Authorization: Bearer $token" "${RHDH_BASE_URL}/api/catalog/entities?filter=kind=api" | jq -r diff --git a/dev-sandbox/rhdh-perf.job.template.yaml b/dev-sandbox/rhdh-perf.job.template.yaml new file mode 100644 index 0000000..497c3d4 --- /dev/null +++ b/dev-sandbox/rhdh-perf.job.template.yaml @@ -0,0 +1,21 @@ +kind: Template +apiVersion: template.openshift.io/v1 +metadata: + name: user-workloads +objects: + - apiVersion: batch/v1 + kind: Job + metadata: + name: rhdh-perf + spec: + template: + spec: + containers: + - name: curl-container + image: quay.io/pmacik-testing/rhdh-perf-testing-client:v1.2 + imagePullPolicy: Always + env: + - name: RHDH_BASE_URL + value: "${RHDH_URL}" + restartPolicy: Never + backoffLimit: 4