Bitbucket Cloud is a Git-based code hosting and collaboration tool, built for teams.
Compass currently supports Bitbucket Cloud as a tool to:
import components from Bitbucket repositories to track them in Compass
automate component management from an external tool with config-as-code
sync component data, such as deployment activity, from Bitbucket to Compass
Components are software artifacts such as services, applications, and libraries. They usually live in repositories in source code management tools, such as Bitbucket Cloud. You can create a catalog listing of these components in Compass by importing them from their Bitbucket repositories.
The process to import component from Bitbucket repositories involves:
integrating Compass with Bitbucket Cloud
selecting the repositories to import
optionally, letting Compass set up config-as-code for your components during the import process
We’ll show you how to import components from Bitbucket repositories.
Before you begin
Before you start importing components, integrate Compass with Bitbucket Cloud:
Install the Bitbucket Cloud app in Compass. Select Apps from the top navigation and select Install on Bitbucket tile.
Select Configure on the Bitbucket tile and connect Compass to the Bitbucket workspace containing your component’s repositories.
In Compass, select Create from the top navigation bar.
Select Import components, then select Configure in front of the Bitbucket option.
If you haven’t installed Bitbucket yet, you’ll see the Install in front of the Bitbucket option instead. Select it to complete the Bitbucket app installation first, then come back here.
Update Bitbucket permissions for Compass, if you’re prompted to do so.
This one-time authorization grants Compass permissions to add the compass.yml configuration files in your repositories. Compass also raises pull requests to merge the changes.
Select Select repositories in the Import components section.
Select repositories containing the components you want to import into Compass.
The Status column shows you whether a repository is available for import.
Select a component type for each component, and proceed to the next step.
Select the component type carefully. You won’t be able to change it once the import completes and creates the component’s catalog listing in Compass.
Select Set up configuration files for all the components to let Compass set up config-as-code for the components you are importing.
If you select this option, Compass adds the compass.yml configuration file to each repository and raises pull requests to merge the changes.
If you do not select this option, Compass imports the components without setting up the configuration files. You can set up the configuration files manually later or choose to manage the components in Compass without setting up config-as-code.
You’ll be able to see if any components failed to import. Follow the import process to import those components again.
If you chose to set up configuration files during the import, approve and merge the pull requests in Bitbucket to complete the component import process.
Once the import completes, search and view your component in Compass.
If you disconnect your Bitbucket workspace from Compass, any components managed with config-as-code disconnect from their repositories and no longer sync with Bitbucket. But don’t worry, the catalog entries of the components you imported earlier remain intact and you can manage them in Compass.