Skip to content

Commit c263619

Browse files
Preserve order of resource server ids
1 parent 3cba56c commit c263619

File tree

3 files changed

+28
-2
lines changed

3 files changed

+28
-2
lines changed

deps/rabbitmq_management/priv/www/js/oidc-oauth/helper.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -393,7 +393,7 @@ export function hasAnyResourceServerReady(oauth, onReadyCallback) {
393393
}
394394
}
395395
oauth.declared_resource_servers_count = oauth.resource_servers.length;
396-
oauth.resource_servers = array.sort((a, b) => a.index - b.index);oauth.resource_servers.filter((resource) =>
396+
oauth.resource_servers = oauth.resource_servers.filter((resource) =>
397397
!notReadyServers.includes(resource.oauth_provider_url) && !notCompliantServers.includes(resource.oauth_provider_url));
398398
oauth.resource_servers.sort((a, b) => a.index - b.index);
399399

selenium/Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ FROM node:24 AS base
33
WORKDIR /code
44

55
COPY package.json package.json
6+
COPY .npmrc .npmrc
67

78
FROM base AS test
89
RUN npm install --verbose

selenium/README.md

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,11 @@ following command:
236236
MOCHA_DOCKER_FILE=\location\of\my\Dockerfile ./run-suites.sh
237237
```
238238

239-
## How to solve : NPM packages are blocked by network firewalls
239+
## How to solve : NPM packages are blocked by network firewalls
240+
241+
This network issue manifests in two stages. One stage is when you run the tests
242+
interactively, i.e. using `npm` directly in the host machine. The steps below configures
243+
npm, in the host machine, so that it is not blocked by network firewalls.
240244

241245
1. Make sure you are connected to the VPN in Full Tunnel mode. Artifactory returns an HTTP 403 forbidden error from anywhere outside the full corporate network.
242246
2. `cd selenium`
@@ -252,3 +256,24 @@ Press ENTER to open in the browser...
252256
8. You should get the message `Login performed successfully. Redirecting to home page.`
253257

254258
For further information, checkout https://github.gwd.broadcom.net/TNZ/rabbitmq-private-docs/wiki/Artifactory-NPM.
259+
260+
If you need to build a `mocha-test` image because you want to run the tests in
261+
silent mode, i.e. in the background, you need to configure NPM in docker.
262+
Follow these steps:
263+
264+
1. Navigate to https://usw1.packages.broadcom.com/
265+
2. Log in with your Broadcom credentials
266+
3. Click on your username in the top-right corner
267+
4. Select "Edit Profile"
268+
5. In the left sidebar, click "Generate an Identity Token"
269+
6. Copy the generated token
270+
7. Edit file selenium/.npmrc and make sure it has this format.
271+
```
272+
registry=https://usw1.packages.broadcom.com/artifactory/api/npm/tds-rabbitmq-npm-virtual/
273+
//usw1.packages.broadcom.com/artifactory/api/npm/tds-rabbitmq-npm-virtual/:_authToken=<paste_here_the_token>
274+
```
275+
Note: The `Dockerfile` copies the .npmrc into the image.
276+
277+
For further information, check out https://github.gwd.broadcom.net/TNZ/rabbitmq-private-docs/wiki/Artifactory-Docker#step-1-generate-artifactory-token.
278+
279+
Note: You will notice that building the mocha-image takes far longer now.

0 commit comments

Comments
 (0)