IBM Cloud CLI
ActionsTags
(2)Verified
This action installs the IBM Cloud CLI and authenticates with IBM Cloud so you can run commands against it.
steps:
- name: Set up ibmcloud CLI
uses: IBM/actions-ibmcloud-cli@v1
with:
api_key: ${{ secrets.IBMCLOUD_API_KEY }}
region: us-south
group: default
plugins: container-service, secrets-manager
- name: Run an ibmcloud CLI command
run: ibmcloud --version
-
api_key
: (optional) API Key to login to IBM Cloud obtained from your IAM settings.If not provided, no attempt will be made to login in and you will need to login with the IBM Cloud CLI directly in a subsequent step.
-
region
: (optional - default:us-south
) Region to access on IBM Cloud. -
group
: (optional - default:default
) Resource group to access on IBM Cloud. -
api
: (optional - default:https://cloud.ibm.com
) API endpoint to IBM Cloud. -
plugins
: (optional) A comma, space, or newline separated list of CLI plugins to be installed.The plugins can listed by name (e.g.
container-service
) or with a specific version (e.g.[email protected]
).For more information about plugins see Extending IBM Cloud CLI with plug-ins.
Examples:
plugins: [email protected], secrets-manager plugins: [email protected] secrets-manager plugins: | [email protected] secrets-manager
-
version
: The version of the IBM Cloud CLI that was installed.This can be accessed in a subsequent step by accessing the outputs as follows:
steps: - name: Set up ibmcloud CLI id: ibmcloud uses: IBM/actions-ibmcloud-cli@v1 - run: ibmcloud --version # => ibmcloud 2.31.0 (6b1eddc-2024-12-05T17:30:20+00:00) - run: echo The version installed is ${{ steps.ibmcloud.outputs.version }} # => The version installed is 2.31.0
The action works on these GitHub-hosted runners images. Runner images not listed below are not supported yet.
OS | Supported |
---|---|
Ubuntu | ubuntu-24.04 (ubuntu-latest ), ubuntu-24.04-arm , ubuntu-22.04 , ubuntu-22.04-arm |
macOS | macos-15 , macos-14 (macos-latest ), macos-13 |
Windows | windows-2025 , windows-2022 (windows-latest ) |
See CONTRIBUTING.md.
The action is available as open source under the terms of the Apache License 2.0.
IBM Cloud CLI is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.