diff --git a/.ibm/pipelines/auth/secrets-rhdh-secrets.yaml b/.ibm/pipelines/auth/secrets-rhdh-secrets.yaml index 0ec98ab1ed..6f2e592adc 100644 --- a/.ibm/pipelines/auth/secrets-rhdh-secrets.yaml +++ b/.ibm/pipelines/auth/secrets-rhdh-secrets.yaml @@ -29,7 +29,7 @@ data: KEYCLOAK_CLIENT_ID: bXljbGllbnQ= KEYCLOAK_CLIENT_SECRET: dGVtcA== ACR_SECRET: dGVtcA== - DH_TARGET_URL: aHR0cDovL3Rlc3QtYmFja3N0YWdlLWN1c3RvbWl6YXRpb24tcHJvdmlkZXItc2hvd2Nhc2UtY2kucmhkaC1wci1vcy1hOTgwNTY1MDgzMGIyMmMzYWVlMjQzZTUxZDc5NTY1ZC0wMDAwLnVzLWVhc3QuY29udGFpbmVycy5hcHBkb21haW4uY2xvdWQ= + DH_TARGET_URL: dGVzdC1iYWNrc3RhZ2UtY3VzdG9taXphdGlvbi1wcm92aWRlci1zaG93Y2FzZS1jaS5yaGRoLXByLW9zLWE5ODA1NjUwODMwYjIyYzNhZWUyNDNlNTFkNzk1NjVkLTAwMDAudXMtZWFzdC5jb250YWluZXJzLmFwcGRvbWFpbi5jbG91ZA== GOOGLE_CLIENT_ID: dGVtcA== GOOGLE_CLIENT_SECRET: dGVtcA== -type: Opaque +type: Opaque \ No newline at end of file diff --git a/.ibm/pipelines/env_variables.sh b/.ibm/pipelines/env_variables.sh index 7674874619..62460f0620 100755 --- a/.ibm/pipelines/env_variables.sh +++ b/.ibm/pipelines/env_variables.sh @@ -67,7 +67,7 @@ KEYCLOAK_REALM='myrealm' KEYCLOAK_CLIENT_ID='myclient' KEYCLOAK_CLIENT_SECRET=$(cat /tmp/secrets/KEYCLOAK_CLIENT_SECRET) ACR_SECRET=$(cat /tmp/secrets/ACR_SECRET) -DH_TARGET_URL=aHR0cDovL3Rlc3QtYmFja3N0YWdlLWN1c3RvbWl6YXRpb24tcHJvdmlkZXItc2hvd2Nhc2UtY2kucmhkaC1wci1vcy1hOTgwNTY1MDgzMGIyMmMzYWVlMjQzZTUxZDc5NTY1ZC0wMDAwLnVzLWVhc3QuY29udGFpbmVycy5hcHBkb21haW4uY2xvdWQ= +DH_TARGET_URL=dGVzdC1iYWNrc3RhZ2UtY3VzdG9taXphdGlvbi1wcm92aWRlci1zaG93Y2FzZS1jaS5yaGRoLXByLW9zLWE5ODA1NjUwODMwYjIyYzNhZWUyNDNlNTFkNzk1NjVkLTAwMDAudXMtZWFzdC5jb250YWluZXJzLmFwcGRvbWFpbi5jbG91ZA== GOOGLE_CLIENT_ID=$(cat /tmp/secrets/GOOGLE_CLIENT_ID) GOOGLE_CLIENT_SECRET=$(cat /tmp/secrets/GOOGLE_CLIENT_SECRET) GOOGLE_ACC_COOKIE=$(cat /tmp/secrets/GOOGLE_ACC_COOKIE) @@ -107,4 +107,4 @@ GKE_SERVICE_ACCOUNT_NAME=$(cat /tmp/secrets/GKE_SERVICE_ACCOUNT_NAME) GKE_CERT_NAME=$(cat /tmp/secrets/GKE_CERT_NAME) GOOGLE_CLOUD_PROJECT=$(cat /tmp/secrets/GOOGLE_CLOUD_PROJECT) -set +a # Stop automatically exporting variables +set +a # Stop automatically exporting variables \ No newline at end of file diff --git a/.ibm/pipelines/openshift-ci-tests.sh b/.ibm/pipelines/openshift-ci-tests.sh index 3c62cb891a..2cc521681c 100755 --- a/.ibm/pipelines/openshift-ci-tests.sh +++ b/.ibm/pipelines/openshift-ci-tests.sh @@ -213,7 +213,9 @@ apply_yaml_files() { GITHUB_APP_CLIENT_SECRET=$(cat /tmp/secrets/GITHUB_APP_4_CLIENT_SECRET) fi - for key in GITHUB_APP_APP_ID GITHUB_APP_CLIENT_ID GITHUB_APP_PRIVATE_KEY GITHUB_APP_CLIENT_SECRET GITHUB_APP_JANUS_TEST_APP_ID GITHUB_APP_JANUS_TEST_CLIENT_ID GITHUB_APP_JANUS_TEST_CLIENT_SECRET GITHUB_APP_JANUS_TEST_PRIVATE_KEY GITHUB_APP_WEBHOOK_URL GITHUB_APP_WEBHOOK_SECRET KEYCLOAK_CLIENT_SECRET ACR_SECRET GOOGLE_CLIENT_ID GOOGLE_CLIENT_SECRET K8S_CLUSTER_TOKEN_ENCODED OCM_CLUSTER_URL GITLAB_TOKEN; do + DH_TARGET_URL=$(echo -n "test-backstage-customization-provider-${project}.${K8S_CLUSTER_ROUTER_BASE}" | base64 -w 0) + + for key in GITHUB_APP_APP_ID GITHUB_APP_CLIENT_ID GITHUB_APP_PRIVATE_KEY GITHUB_APP_CLIENT_SECRET GITHUB_APP_JANUS_TEST_APP_ID GITHUB_APP_JANUS_TEST_CLIENT_ID GITHUB_APP_JANUS_TEST_CLIENT_SECRET GITHUB_APP_JANUS_TEST_PRIVATE_KEY GITHUB_APP_WEBHOOK_URL GITHUB_APP_WEBHOOK_SECRET KEYCLOAK_CLIENT_SECRET ACR_SECRET GOOGLE_CLIENT_ID GOOGLE_CLIENT_SECRET K8S_CLUSTER_TOKEN_ENCODED OCM_CLUSTER_URL GITLAB_TOKEN DH_TARGET_URL; do sed -i "s|${key}:.*|${key}: ${!key}|g" "$dir/auth/secrets-rhdh-secrets.yaml" done diff --git a/.ibm/pipelines/resources/config_map/app-config-rhdh.yaml b/.ibm/pipelines/resources/config_map/app-config-rhdh.yaml index ca054ba60a..ad49b0850c 100644 --- a/.ibm/pipelines/resources/config_map/app-config-rhdh.yaml +++ b/.ibm/pipelines/resources/config_map/app-config-rhdh.yaml @@ -53,6 +53,10 @@ dynamicPlugins: title: Dark Dynamic variant: dark backend: + reading: + allow: + - host: 'github.com' + - host: ${DH_TARGET_URL} auth: keys: - secret: temp @@ -101,17 +105,13 @@ auth: development: clientId: ${GOOGLE_CLIENT_ID} clientSecret: ${GOOGLE_CLIENT_SECRET} +techRadar: + url: "http://${DH_TARGET_URL}/tech-radar" proxy: skipInvalidProxies: true # endpoints: {} endpoints: # Other Proxies - # customize developer hub instance - '/developer-hub': - target: ${DH_TARGET_URL} - changeOrigin: true - # Change to "false" in case of using self hosted cluster with a self-signed certificate - secure: false '/acr/api': target: 'https://rhdhqetest.azurecr.io/acr/v1/' changeOrigin: true diff --git a/.ibm/pipelines/value_files/values_showcase.yaml b/.ibm/pipelines/value_files/values_showcase.yaml index cb5268bf28..d4ad325217 100644 --- a/.ibm/pipelines/value_files/values_showcase.yaml +++ b/.ibm/pipelines/value_files/values_showcase.yaml @@ -94,11 +94,11 @@ global: disabled: false - package: ./dynamic-plugins/dist/red-hat-developer-hub-backstage-plugin-bulk-import disabled: false - # Enable tech-radar plugin. + # Enable tech-radar plugins. - package: ./dynamic-plugins/dist/backstage-community-plugin-tech-radar disabled: false - package: ./dynamic-plugins/dist/backstage-community-plugin-tech-radar-backend-dynamic - disabled: true + disabled: false - package: ./dynamic-plugins/dist/backstage-community-plugin-acr disabled: false - package: ./dynamic-plugins/dist/roadiehq-scaffolder-backend-module-http-request-dynamic diff --git a/e2e-tests/playwright/e2e/plugins/dynamic-plugins-info/dynamic-plugins-info.spec.ts b/e2e-tests/playwright/e2e/plugins/dynamic-plugins-info/dynamic-plugins-info.spec.ts index 16b05ae243..1ca59c8b68 100644 --- a/e2e-tests/playwright/e2e/plugins/dynamic-plugins-info/dynamic-plugins-info.spec.ts +++ b/e2e-tests/playwright/e2e/plugins/dynamic-plugins-info/dynamic-plugins-info.spec.ts @@ -38,14 +38,14 @@ test.describe("dynamic-plugins-info UI tests", () => { await uiHelper.verifyRowsInTable(["backstage-plugin-techdocs"], true); }); - test.skip("it should have a backstage-plugin-tech-radar plugin which is Enabled and Preinstalled", async ({ + test("it should have a plugin-tech-radar plugin which is Enabled and Preinstalled", async ({ page, }) => { await page .getByPlaceholder("Filter") - .pressSequentially("backstage-plugin-tech-radar\n", { delay: 300 }); + .pressSequentially("plugin-tech-radar\n", { delay: 300 }); const row = await page.locator( - UIhelperPO.rowByText("backstage-plugin-tech-radar"), + UIhelperPO.rowByText("backstage-community-plugin-tech-radar"), ); expect(await row.locator("td").nth(2).innerText()).toBe("Yes"); // enabled expect(await row.locator("td").nth(3).innerText()).toBe("Yes"); // preinstalled diff --git a/e2e-tests/playwright/e2e/plugins/quick-access-and-tech-radar.spec.ts b/e2e-tests/playwright/e2e/plugins/quick-access-and-tech-radar.spec.ts index ac16669451..981d53e213 100644 --- a/e2e-tests/playwright/e2e/plugins/quick-access-and-tech-radar.spec.ts +++ b/e2e-tests/playwright/e2e/plugins/quick-access-and-tech-radar.spec.ts @@ -6,7 +6,7 @@ import { TechRadar } from "../../support/pages/TechRadar"; // Pre-req: Enable backstage-plugin-tech-radar and backstage-plugin-tech-radar-backend Plugin -test.describe.skip("Test Customized Quick Access and tech-radar plugin", () => { +test.describe("Test Customized Quick Access and tech-radar plugin", () => { test.beforeEach(async ({ page }) => { const common = new Common(page); await common.loginAsGuest();