diff --git a/.github/workflows/integration-test.yml b/.github/workflows/integration-test.yml
index feac55105..d373d4b28 100644
--- a/.github/workflows/integration-test.yml
+++ b/.github/workflows/integration-test.yml
@@ -2,6 +2,10 @@ name: Integration Tests
on: [push, pull_request]
+env:
+ TEST_BROWSER_HEADLESS: 1
+ CI: 1
+
jobs:
tests:
name: Run integration tests
@@ -9,12 +13,13 @@ jobs:
steps:
- name: Download OpenSearch Core
run: |
- wget https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/1.3.6/latest/linux/x64/tar/builds/opensearch/dist/opensearch-min-1.3.6-linux-x64.tar.gz
+ wget https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/2.4.0/latest/linux/x64/tar/builds/opensearch/dist/opensearch-min-2.4.0-linux-x64.tar.gz
tar -xzf opensearch-*.tar.gz
rm -f opensearch-*.tar.gz
- name: Download OpenSearch Security Plugin
- run: wget -O opensearch-security.zip https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/1.3.6/latest/linux/x64/tar/builds/opensearch/plugins/opensearch-security-1.3.6.0.zip
+ run: wget -O opensearch-security.zip https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/2.4.0/latest/linux/x64/tar/builds/opensearch/plugins/opensearch-security-2.4.0.0.zip
+
- name: Run OpenSearch with plugin
run: |
@@ -37,21 +42,21 @@ jobs:
WORKDIR /opensearch/
ENTRYPOINT /docker-host/os-ep.sh
EOF
- docker run -d -p 9200:9200 -p 9600:9600 -i opensearch-test:latest
+ docker run -d --network=host -i opensearch-test:latest
- name: Checkout OpenSearch Dashboard
uses: actions/checkout@v2
with:
path: OpenSearch-Dashboards
repository: opensearch-project/OpenSearch-Dashboards
- ref: '1.3'
+ ref: '2.x'
fetch-depth: 0
-
+
- name: Create plugins dir
run: |
cd ./OpenSearch-Dashboards
mkdir -p plugins
-
+
- name: Checkout OpenSearch Dashboard Security plugin
uses: actions/checkout@v2
with:
@@ -66,30 +71,30 @@ jobs:
# id: osd_version
# run: |
# echo "::set-output name=osd_version::$(jq -r '.opensearchDashboards.version' ./OpenSearch-Dashboards/plugins/security-dashboards-plugin/package.json)"
-
+
# - name: Check OpenSearch Dashboards release tag
# run: |
# cd ./OpenSearch-Dashboards
# git checkout tags/${{ steps.osd_version.outputs.osd_version }} -b v${{ steps.osd_version.outputs.osd_version }}
-
+
- name: Get node and yarn versions
id: versions
run: |
echo "::set-output name=node_version::$(cat ./OpenSearch-Dashboards/.node-version)"
echo "::set-output name=yarn_version::$(jq -r '.engines.yarn' ./OpenSearch-Dashboards/package.json)"
-
+
- name: Setup node
uses: actions/setup-node@v1
with:
node-version: ${{ steps.versions.outputs.node_version }}
registry-url: 'https://registry.npmjs.org'
-
+
- name: Install correct yarn version for OpenSearch Dashboards
run: |
npm uninstall -g yarn
echo "Installing yarn ${{ steps.versions_step.outputs.yarn_version }}"
npm i -g yarn@${{ steps.versions.outputs.yarn_version }}
-
+
- name: Check OpenSearch Running
continue-on-error: true
run: curl -XGET https://localhost:9200 -u 'admin:admin' -k
@@ -98,7 +103,8 @@ jobs:
run: |
cd ./OpenSearch-Dashboards
yarn osd bootstrap
-
+ node scripts/build_opensearch_dashboards_platform_plugins.js
+
- name: Run integration tests
run: |
echo "check if opensearch is ready"
diff --git a/.github/workflows/unit-test.yml b/.github/workflows/unit-test.yml
index 38bcd93d2..8383ed98c 100644
--- a/.github/workflows/unit-test.yml
+++ b/.github/workflows/unit-test.yml
@@ -13,7 +13,7 @@ jobs:
with:
path: OpenSearch-Dashboards
repository: opensearch-project/OpenSearch-Dashboards
- ref: '1.x'
+ ref: 'main'
fetch-depth: 0
- name: Create plugins dir
run: |
@@ -46,7 +46,7 @@ jobs:
run: |
npm uninstall -g yarn
echo "Installing yarn ${{ steps.versions_step.outputs.yarn_version }}"
- npm i -g yarn@${{ steps.versions.outputs.yarn_version }}
+ npm i -g yarn@${{ steps.versions.outputs.yarn_version }} --ignore-engines
- name: Bootstrap OpenSearch Dashboards
run: |
cd ./OpenSearch-Dashboards
diff --git a/.idea/.gitignore b/.idea/.gitignore
new file mode 100644
index 000000000..26d33521a
--- /dev/null
+++ b/.idea/.gitignore
@@ -0,0 +1,3 @@
+# Default ignored files
+/shelf/
+/workspace.xml
diff --git a/.idea/misc.xml b/.idea/misc.xml
new file mode 100644
index 000000000..639900d13
--- /dev/null
+++ b/.idea/misc.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/modules.xml b/.idea/modules.xml
new file mode 100644
index 000000000..2b411b895
--- /dev/null
+++ b/.idea/modules.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/security-dashboards-plugin.iml b/.idea/security-dashboards-plugin.iml
new file mode 100644
index 000000000..d6ebd4805
--- /dev/null
+++ b/.idea/security-dashboards-plugin.iml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/vcs.xml b/.idea/vcs.xml
new file mode 100644
index 000000000..35eb1ddfb
--- /dev/null
+++ b/.idea/vcs.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/DEVELOPER_GUIDE.md b/DEVELOPER_GUIDE.md
index 0118872da..9e4113fd6 100644
--- a/DEVELOPER_GUIDE.md
+++ b/DEVELOPER_GUIDE.md
@@ -28,6 +28,7 @@ plugins.security.allow_default_init_securityindex: true
plugins.security.authcz.admin_dn:
- CN=kirk,OU=client,O=client,L=test, C=de
+plugins.security.unsupported.restapi.allow_securityconfig_modification: true
plugins.security.audit.type: internal_opensearch
plugins.security.enable_snapshot_restore_privilege: true
plugins.security.check_snapshot_restore_write_privileges: true
@@ -71,6 +72,8 @@ yarn build
We should be able to run Dashboards now changing back to its base directory and running `yarn start`. Navigating to the URL given as console output (something like `http://localhost:5601/omf`) you should now be able to log in with user `admin` and password `admin`.
+To run selenium based integration tests, download and export the firefox web-driver to your PATH. Also, run `node scripts/build_opensearch_dashboards_platform_plugins.js` or `yarn start` before running the tests. This is essential to generate the bundles.
+
## Submitting Changes
See [CONTRIBUTING](CONTRIBUTING.md).
diff --git a/package.json b/package.json
index 06b61aa1e..e16c43888 100644
--- a/package.json
+++ b/package.json
@@ -15,20 +15,23 @@
"build": "yarn plugin-helpers build && node build_tools/rename_zip.js",
"start": "node ../../scripts/opensearch-dashboards --dev",
"lint:es": "node ../../scripts/eslint",
- "lint:sass": "node ../../scripts/sasslint",
- "lint": "yarn run lint:es && yarn run lint:sass",
+ "lint": "yarn run lint:es && yarn run lint:style",
+ "pretest:jest_server": "node ./test/jest_integration/runIdpServer.js &",
"test:jest_server": "node ./test/run_jest_tests.js --config ./test/jest.config.server.js",
"test:jest_ui": "node ./test/run_jest_tests.js --config ./test/jest.config.ui.js"
},
"devDependencies": {
- "@elastic/eslint-import-resolver-kibana": "link:../../packages/osd-eslint-import-resolver-opensearch-dashboards",
- "typescript": "4.0.2",
+ "@elastic/eslint-import-resolver-kibana": "link:../../packages/osd-eslint-import-resolver-opensearch-dashboards",
+ "@testing-library/react-hooks": "^7.0.2",
+ "@types/hapi__wreck": "^15.0.1",
"gulp-rename": "2.0.0",
- "@testing-library/react-hooks": "^3.4.1",
- "@types/hapi__wreck": "^15.0.1"
+ "saml-idp": "^1.2.1",
+ "selenium-webdriver": "^4.0.0-alpha.7",
+ "selfsigned": "^2.0.1",
+ "typescript": "4.0.2"
},
"dependencies": {
- "@hapi/wreck": "^15.0.2",
+ "@hapi/wreck": "^17.1.0",
"@hapi/cryptiles": "5.0.0",
"html-entities": "1.3.1"
}
diff --git a/public/apps/account/account-nav-button.tsx b/public/apps/account/account-nav-button.tsx
index 1100e9f31..7bd0e578b 100644
--- a/public/apps/account/account-nav-button.tsx
+++ b/public/apps/account/account-nav-button.tsx
@@ -93,7 +93,11 @@ export function AccountNavButton(props: {
{resolveTenantName(props.tenant || '', username)}}
+ label={
+
+ {resolveTenantName(props.tenant || '', username)}
+
+ }
/>
@@ -140,7 +144,7 @@ export function AccountNavButton(props: {
);
return (
-
+