Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Vault->OpenBao in the UI #128

Merged
merged 3 commits into from
Feb 26, 2024

Conversation

cipherboy
Copy link
Member

@cipherboy cipherboy commented Feb 8, 2024

This updates the UI to replace references to Vault with references to OpenBao instead. References to Vault Enterprise were retained, as were the docs.

I mostly went through this with grep; I'd suggest using a build (make static-dist dev-ui -- see build dependencies under ui/README.md) to walk through it to find any missing references, IMO.

Related: #74


Note: this PR will not resolve the branding assets issue as mentioned in #74, so that will have to remain open.

@cipherboy cipherboy changed the title Update vault UI references Update Vault->OpenBao in the UI Feb 8, 2024
@cipherboy cipherboy force-pushed the update-vault-ui-references branch 2 times, most recently from 4fc8094 to d73ba38 Compare February 12, 2024 02:51
@cipherboy cipherboy mentioned this pull request Feb 22, 2024
Resolves: openbao#74

Signed-off-by: Alexander Scheel <alexander.m.scheel@gmail.com>
Signed-off-by: Alexander Scheel <alexander.m.scheel@gmail.com>
These are a mix of Vault Enterprise only components and removed auth or
secrets engines.

Signed-off-by: Alexander Scheel <alexander.m.scheel@gmail.com>
@cipherboy
Copy link
Member Author

This gets farther now, but I'm not seeing the error:

test output
$ yarn run test:oss
Browserslist: caniuse-lite is outdated. Please run:
  npx browserslist@latest --update-db
  Why you should do it regularly: https://github.com/browserslist/browserslist#browsers-data-updating

$ bao server -dev -dev-ha -dev-transactional -dev-root-token-id=root -dev-listen-address=127.0.0.1:9200
$ ember test -f=!enterprise
==> OpenBao server configuration:

Administrative Namespace: 
             Api Address: http://127.0.0.1:9200
                     Cgo: disabled
         Cluster Address: https://127.0.0.1:9201
   Environment Variables: BERRY_BIN_FOLDER, COLORTERM, DBUS_SESSION_BUS_ADDRESS, DEBUGINFOD_URLS, DESKTOP_SESSION, DISPLAY, DOCKER_HOST, EDITOR, GDMSESSION, GDM_LANG, GIT_EDITOR, HISTCONTROL, HISTIGNORE, HISTSIZE, HOME, HOSTNAME, INIT_CWD, INVOCATION_ID, JOURNAL_STREAM, LANG, LESSOPEN, LOGNAME, LS_COLORS, MAIL, MAKEFLAGS, MAKELEVEL, MAKE_TERMERR, MAKE_TERMOUT, MANAGERPID, MEMORY_PRESSURE_WATCH, MEMORY_PRESSURE_WRITE, MFLAGS, MOZ_GMP_PATH, OLDPWD, PATH, PROJECT_CWD, PWD, P_HOST, P_USER, QT_IM_MODULE, SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS, SESSION_MANAGER, SHELL, SHLVL, SSH_AGENT_PID, SSH_AUTH_SOCK, STEAM_FRAME_FORCE_CLOSE, SYSTEMD_EXEC_PID, TERM, TILIX_ID, USER, USERNAME, VIRT_ADDR, VISUAL, VTE_VERSION, WINDOWPATH, XAUTHORITY, XDG_CURRENT_DESKTOP, XDG_DATA_DIRS, XDG_MENU_PREFIX, XDG_RUNTIME_DIR, XDG_SESSION_CLASS, XDG_SESSION_DESKTOP, XDG_SESSION_TYPE, XMODIFIERS, YARN_IGNORE_CWD, _, npm_config_user_agent, npm_execpath, npm_lifecycle_event, npm_node_execpath, npm_package_json, npm_package_name, npm_package_version
              Go Version: go1.21.6
              Listener 1: tcp (addr: "127.0.0.1:9200", cluster address: "127.0.0.1:9201", max_request_duration: "1m30s", max_request_size: "33554432", tls: "disabled")
               Log Level: 
                   Mlock: supported: true, enabled: false
           Recovery Mode: false
                 Storage: inmem_transactional_ha (HA available)
                 Version: OpenBao v1.14.9, built 2024-02-12T10:37:08Z
             Version Sha: d06a3f7b64ca0e14f6fcad6b73028a24506dda11+CHANGES

==> OpenBao server started! Log data will stream in below:

2024-02-23T19:32:39.862-0500 [INFO]  proxy environment: http_proxy="" https_proxy="" no_proxy=""
2024-02-23T19:32:39.863-0500 [WARN]  no `api_addr` value specified in config or in VAULT_API_ADDR; falling back to detection if possible, but this value should be manually set
2024-02-23T19:32:39.863-0500 [INFO]  core: Initializing version history cache for core
2024-02-23T19:32:39.863-0500 [INFO]  core: security barrier not initialized
2024-02-23T19:32:39.863-0500 [INFO]  core: security barrier initialized: stored=1 shares=1 threshold=1
2024-02-23T19:32:39.872-0500 [INFO]  core: post-unseal setup starting
2024-02-23T19:32:39.873-0500 [INFO]  core: loaded wrapping token key
2024-02-23T19:32:39.873-0500 [INFO]  core: successfully setup plugin catalog: plugin-directory=""
2024-02-23T19:32:39.873-0500 [INFO]  core: no mounts; adding default mount table
2024-02-23T19:32:39.874-0500 [INFO]  core: successfully mounted: type=cubbyhole version="v1.14.9+builtin.bao" path=cubbyhole/ namespace="ID: root. Path: "
2024-02-23T19:32:39.874-0500 [INFO]  core: successfully mounted: type=system version="v1.14.9+builtin.bao" path=sys/ namespace="ID: root. Path: "
2024-02-23T19:32:39.875-0500 [INFO]  core: successfully mounted: type=identity version="v1.14.9+builtin.bao" path=identity/ namespace="ID: root. Path: "
2024-02-23T19:32:39.877-0500 [INFO]  core: successfully mounted: type=token version="v1.14.9+builtin.bao" path=token/ namespace="ID: root. Path: "
2024-02-23T19:32:39.877-0500 [INFO]  rollback: Starting the rollback manager with 256 workers
2024-02-23T19:32:39.877-0500 [INFO]  rollback: starting rollback manager
2024-02-23T19:32:39.877-0500 [INFO]  core: restoring leases
2024-02-23T19:32:39.877-0500 [INFO]  expiration: lease restore complete
2024-02-23T19:32:39.878-0500 [INFO]  identity: entities restored
2024-02-23T19:32:39.878-0500 [INFO]  identity: groups restored
2024-02-23T19:32:39.878-0500 [INFO]  core: Recorded vault version: vault version=1.14.9 upgrade time="2024-02-24 00:32:39.878224452 +0000 UTC" build date=2024-02-12T10:37:08Z
2024-02-23T19:32:39.878-0500 [INFO]  core: post-unseal setup complete
2024-02-23T19:32:39.878-0500 [INFO]  core: root token generated
2024-02-23T19:32:39.878-0500 [INFO]  core: pre-seal teardown starting
2024-02-23T19:32:39.878-0500 [INFO]  rollback: stopping rollback manager
2024-02-23T19:32:39.878-0500 [INFO]  core: pre-seal teardown complete
2024-02-23T19:32:39.879-0500 [INFO]  core.cluster-listener.tcp: starting listener: listener_address=127.0.0.1:9201
2024-02-23T19:32:39.879-0500 [INFO]  core.cluster-listener: serving cluster requests: cluster_listen_address=127.0.0.1:9201
2024-02-23T19:32:39.879-0500 [INFO]  core: vault is unsealed
2024-02-23T19:32:39.879-0500 [INFO]  core: entering standby mode
2024-02-23T19:32:39.879-0500 [INFO]  core: acquired lock, enabling active operation
2024-02-23T19:32:39.883-0500 [INFO]  core: post-unseal setup starting
2024-02-23T19:32:39.883-0500 [INFO]  core: loaded wrapping token key
2024-02-23T19:32:39.883-0500 [INFO]  core: successfully setup plugin catalog: plugin-directory=""
2024-02-23T19:32:39.884-0500 [INFO]  core: successfully mounted: type=system version="v1.14.9+builtin.bao" path=sys/ namespace="ID: root. Path: "
2024-02-23T19:32:39.884-0500 [INFO]  core: successfully mounted: type=identity version="v1.14.9+builtin.bao" path=identity/ namespace="ID: root. Path: "
2024-02-23T19:32:39.884-0500 [INFO]  core: successfully mounted: type=cubbyhole version="v1.14.9+builtin.bao" path=cubbyhole/ namespace="ID: root. Path: "
2024-02-23T19:32:39.885-0500 [INFO]  core: successfully mounted: type=token version="v1.14.9+builtin.bao" path=token/ namespace="ID: root. Path: "
2024-02-23T19:32:39.885-0500 [INFO]  rollback: Starting the rollback manager with 256 workers
2024-02-23T19:32:39.885-0500 [INFO]  rollback: starting rollback manager
2024-02-23T19:32:39.885-0500 [INFO]  core: restoring leases
2024-02-23T19:32:39.886-0500 [INFO]  expiration: lease restore complete
2024-02-23T19:32:39.886-0500 [INFO]  identity: entities restored
2024-02-23T19:32:39.886-0500 [INFO]  identity: groups restored
2024-02-23T19:32:39.886-0500 [INFO]  core: post-unseal setup complete
2024-02-23T19:32:40.880-0500 [INFO]  expiration: revoked lease: lease_id=auth/token/root/h35ea05ca0574b23f5117551984d125475dfd63aa5125accefb8b329076ea8de6
2024-02-23T19:32:40.883-0500 [INFO]  core: successful mount: namespace="" path=secret/ type=kv version=""
2024-02-23T19:32:40.892-0500 [INFO]  secrets.kv.kv_9b82df31: collecting keys to upgrade
2024-02-23T19:32:40.892-0500 [INFO]  secrets.kv.kv_9b82df31: done collecting keys: num_keys=1
2024-02-23T19:32:40.892-0500 [INFO]  secrets.kv.kv_9b82df31: upgrading keys finished
WARNING! dev mode is enabled! In this mode, Vault runs entirely in-memory
and starts unsealed with a single unseal key. The root token is already
authenticated to the CLI, so you can immediately begin using Vault.

You may need to set the following environment variables:

    $ export VAULT_ADDR='http://127.0.0.1:9200'

The unseal key and root token are displayed below in case you want to
seal/unseal the Vault or re-authenticate.

Unseal Key: kcQocwfTo7r+iBqSUf+MQNnaBDF60MS8lW3zs2B84So=
Root Token: root

Development mode should NOT be used in production installations!

VAULT SERVER READY
Browserslist: caniuse-lite is outdated. Please run:
npx browserslist@latest --update-db

Why you should do it regularly:
https://github.com/browserslist/browserslist#browsers-data-updating
WARNING: Node v20.10.0 is not tested against Ember CLI on your platform. We recommend that you use the most-recent "Active LTS" version of Node.js. See https://git.io/v7S5n for details.
Environment: test
⠙ building... Browserslist: caniuse-lite is outdated. Please run:
  npx browserslist@latest --update-db
  Why you should do it regularly: https://github.com/browserslist/browserslist#browsers-data-updating
Browserslist: caniuse-lite is outdated. Please run:
  npx browserslist@latest --update-db
  Why you should do it regularly: https://github.com/browserslist/browserslist#browsers-data-updating
⠸ building... [Babel: ember-get-config > applyPatches]Browserslist: caniuse-lite is outdated. Please run:
  npx browserslist@latest --update-db
  Why you should do it regularly: https://github.com/browserslist/browserslist#browsers-data-updating
WARNING: Detected collisions between .js and .ts files of the same name. This can result in nondeterministic build output; see https://git.io/JvIwo for more information.
  - vault/services/flash-messages.{js,ts}
⠋ building... [Package /assets/vendor.js]Deprecation Warning: Using / for division outside of calc() is deprecated and will be removed in Dart Sass 2.0.0.

Recommendation: math.div(str-length($svg), $slice) or calc(str-length($svg) / $slice)

More info and automated migrator: https://sass-lang.com/d/slash-div

   ╷
17 │     $loops: ceil(str-length($svg) / $slice);
   │                  ^^^^^^^^^^^^^^^^^^^^^^^^^
   ╵
    /tmp/broccoli-8355709fzc7Xau3cEY/out-1039-funnel_funnel_styles/app/styles/sass-svg-uri/_svg-uri.scss 17:18    svg-uri()
    /tmp/broccoli-8355709fzc7Xau3cEY/out-1039-funnel_funnel_styles/app/styles/core/checkbox-and-radio.scss 75:12  @import
    /tmp/broccoli-8355709fzc7Xau3cEY/out-1039-funnel_funnel_styles/app/styles/core.scss 28:9                      @import
    /tmp/broccoli-8355709fzc7Xau3cEY/out-1039-funnel_funnel_styles/app/styles/app.scss 10:9                       root stylesheet

⠸ building... [ember-auto-import-webpack]autoprefixer: /home/cipherboy/GitHub/openbao/openbao/ui/assets/vault.css:10102:3: Replace fill-available to stretch, because spec had been changed
cleaning up...
Built project successfully. Stored in "../http/web_ui".
(node:835570) [DEP0128] DeprecationWarning: Invalid 'main' field in '/home/cipherboy/GitHub/openbao/openbao/ui/node_modules/fireworm/package.json' of 'fireworm.js'. Please either fix that or report it to the module author
(Use `node-20 --trace-deprecation ...` to show where the warning was created)
2024-02-23T19:33:22.319-0500 [INFO]  core: enabled credential backend: path=userpass-1-f3e2ebf7-6f64-45f4-9d38-361daed65b11/ type=userpass version=""
2024-02-23T19:33:22.398-0500 [INFO]  core: enabled credential backend: path=userpass-2-f3e2ebf7-6f64-45f4-9d38-361daed65b11/ type=userpass version=""
2024-02-23T19:33:22.631-0500 [INFO]  core: disabled credential backend: path=auth/userpass-1-f3e2ebf7-6f64-45f4-9d38-361daed65b11/
2024-02-23T19:33:22.650-0500 [INFO]  core: disabled credential backend: path=auth/userpass-2-f3e2ebf7-6f64-45f4-9d38-361daed65b11/
2024-02-23T19:33:22.986-0500 [INFO]  core: enabled credential backend: path=userpass-1.2310031433052593/ type=userpass version=""
2024-02-23T19:33:23.022-0500 [INFO]  core: mount tuning of description successful: path=auth/userpass-1.2310031433052593/ description=""
2024-02-23T19:33:23.023-0500 [INFO]  core: mount tuning of token_type successful: path=auth/userpass-1.2310031433052593/ token_type=default-service
2024-02-23T19:33:23.516-0500 [INFO]  core: enabled credential backend: path=userpass-2.2310031433052595/ type=userpass version=""
2024-02-23T19:33:23.546-0500 [INFO]  core: mount tuning of description successful: path=auth/userpass-2.2310031433052595/ description=""
2024-02-23T19:33:23.547-0500 [INFO]  core: mount tuning of token_type successful: path=auth/userpass-2.2310031433052595/ token_type=default-service
2024-02-23T19:33:24.613-0500 [INFO]  core: enabled credential backend: path=auth-list-userpass-c87de073-6c45-4305-8262-22f618fa662c/ type=userpass version=""
2024-02-23T19:33:24.896-0500 [INFO]  core: disabled credential backend: path=auth/auth-list-userpass-c87de073-6c45-4305-8262-22f618fa662c/
2024-02-23T19:33:25.056-0500 [INFO]  core: enabled credential backend: path=auth-list-ldap-c87de073-6c45-4305-8262-22f618fa662c/ type=ldap version=""
2024-02-23T19:33:25.428-0500 [INFO]  core: disabled credential backend: path=auth/auth-list-ldap-c87de073-6c45-4305-8262-22f618fa662c/
2024-02-23T19:33:25.592-0500 [INFO]  core: enabled credential backend: path=auth-list-jwt-c87de073-6c45-4305-8262-22f618fa662c/ type=jwt version=""
2024-02-23T19:33:26.046-0500 [INFO]  core: enabled credential backend: path=auth-list-oidc-c87de073-6c45-4305-8262-22f618fa662c/ type=oidc version=""
2024-02-23T19:33:26.474-0500 [INFO]  core: enabled credential backend: path=auth-list-radius-c87de073-6c45-4305-8262-22f618fa662c/ type=radius version=""
2024-02-23T19:33:26.782-0500 [INFO]  core: disabled credential backend: path=auth/auth-list-radius-c87de073-6c45-4305-8262-22f618fa662c/
2024-02-23T19:33:32.131-0500 [INFO]  core: enabled credential backend: path=cluster-userpass-cbc5a395-3ece-467a-bb20-0d1d2bb2b704/ type=userpass version=""
2024-02-23T19:33:32.807-0500 [INFO]  core: successful mount: namespace="" path=console-route-1/ type=kv version=""
2024-02-23T19:33:32.827-0500 [INFO]  core: successful mount: namespace="" path=console-route-2/ type=kv version=""
2024-02-23T19:33:32.847-0500 [INFO]  core: successful mount: namespace="" path=console-route-3/ type=kv version=""
2024-02-23T19:33:32.931-0500 [INFO]  core: successfully unmounted: path=console-route-1/ namespace=""
2024-02-23T19:33:32.950-0500 [INFO]  core: successfully unmounted: path=console-route-2/ namespace=""
2024-02-23T19:33:32.970-0500 [INFO]  core: successfully unmounted: path=console-route-3/ namespace=""

1..71
# tests 71
# pass  63
# skip  7
# todo  0
# fail  1
Testem finished with non-zero exit code. Tests failed.

Error: Command failed with exit code 1: ember test -f=!enterprise
    at makeError (/home/cipherboy/GitHub/openbao/openbao/ui/node_modules/execa/lib/error.js:59:11)
    at handlePromise (/home/cipherboy/GitHub/openbao/openbao/ui/node_modules/execa/index.js:114:26)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async /home/cipherboy/GitHub/openbao/openbao/ui/scripts/start-vault.js:72:7 {
  shortMessage: 'Command failed with exit code 1: ember test -f=!enterprise',
  command: 'ember test -f=!enterprise',
  exitCode: 1,
  signal: undefined,
  signalDescription: undefined,
  stdout: undefined,
  stderr: undefined,
  failed: true,
  timedOut: false,
  isCanceled: false,
  killed: false
}
make: *** [Makefile:11: test] Error 1

@naphelps naphelps self-requested a review February 26, 2024 19:22
Copy link
Member

@naphelps naphelps left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@naphelps naphelps merged commit 3b5ad0c into openbao:main Feb 26, 2024
3 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants