mirror of
https://github.com/redhat-developer/odo.git
synced 2025-10-19 03:06:19 +03:00
Install and use a reverse proxy for staging devfile registry (#5922)
* Kubernetes Manifests to deploy nginx reverse proxy for staging devfile registry * Get the external address of the loadBalancer service for devfile proxy * If DEVFILE_PROXY is defined, use it as Devfile registry * Fix get address from Windows * Add some log displaying proxy address found * Filter requests on user agent * Add Go-http-client user-agent * Add doc
This commit is contained in:
@@ -12,6 +12,8 @@ cleanup_namespaces
|
||||
export SKIP_USER_LOGIN_TESTS=true
|
||||
(
|
||||
set -e
|
||||
export DEVFILE_PROXY="$(kubectl get svc -n devfile-proxy nginx -o jsonpath='{.status.loadBalancer.ingress[0].hostname}' || true)"
|
||||
echo Using Devfile proxy: ${DEVFILE_PROXY}
|
||||
make install
|
||||
make test-integration
|
||||
make test-e2e
|
||||
|
||||
@@ -13,6 +13,8 @@ cleanup_namespaces
|
||||
|
||||
(
|
||||
set -e
|
||||
export DEVFILE_PROXY="$(kubectl get svc -n devfile-proxy nginx -o jsonpath='{.status.loadBalancer.ingress[0].hostname}' || true)"
|
||||
echo Using Devfile proxy: ${DEVFILE_PROXY}
|
||||
make install
|
||||
make test-integration
|
||||
make test-e2e
|
||||
|
||||
@@ -64,6 +64,14 @@ function Run-Test {
|
||||
oc login -u apikey -p ${API_KEY} ${IBM_OPENSHIFT_ENDPOINT}
|
||||
Check-ExitCode $LASTEXITCODE
|
||||
|
||||
Shout "Getting Devfile proxy address"
|
||||
$DEVFILE_PROXY=$(oc get svc -n devfile-proxy nginx -o jsonpath='{.status.loadBalancer.ingress[0].hostname}')
|
||||
if ( $LASTEXITCODE -eq 0 )
|
||||
{
|
||||
Shout "Using Devfile proxy: $DEVFILE_PROXY"
|
||||
[Environment]::SetEnvironmentVariable("DEVFILE_PROXY", "$DEVFILE_PROXY")
|
||||
}
|
||||
|
||||
Shout "Create Binary"
|
||||
make install
|
||||
Shout "Running test"
|
||||
|
||||
Reference in New Issue
Block a user