Viewing Orbs as a Non-admin

The following example is a workaround to view all orbs if a user is not an admin on server. This is not something that's currently available in the UI. There is an existing feature request for this if you would like to add a vote:

Prerequisites

You should have the CircleCI CLI orb installed and an API token added to project settings or a context.

Workaround

The idea here would be to use a scheduled pipeline to run CLI command against your server host weekly (or as frequently as you'd like) which users can check on to see the available orbs without requiring to load the CLI and configure it locally.

Using the following simple config, with the CLI orb imported and a token as $CIRCLE_TOKEN env var/context, this can be run in CI which will output the orbs available on the specified host.

 

Example

version: 2.1

orbs:
cli: circleci/circleci-cli@0.1.9

jobs:
use-install-command:
docker:
- image: circleci/circleci-cli:latest
steps:
- cli/install
- run: echo "the CLI is now installed"

check-orbs:
docker:
- image: cimg/base:current
steps:
- checkout
- cli/install
- run: circleci version
- run: circleci orb list --host https://<hostnamehere> --token $CIRCLE_TOKEN

workflows:
say-hello-workflow:
jobs:
- use-install-command
- check-orbs

 

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Article is closed for comments.