Lighthouse

Our Lighthouse integration enables you to turn issues flagged in Code Climate into Lighthouse tickets in one quick click. For example, on your Feed page, mouse over a smell and click the "ticket" icon.

663

Note: For an organization-owned repository, you must be in an organization's Owners group to perform the actions described in this article. Alternatively, if you added the repository in question by clicking Add Open Source Repo, you must have GitHub-rights to administer the repository.

Show Me How

The steps below explain how to set up and test Code Climate's Lighthouse integration. Note that these steps will require you to move back and forth between Code Climate and Lighthouse.

  1. In Lighthouse, copy your subdomain. This can be found in any URL while viewing your Lighthouse project. Copy the text between the https:// and the end of the domain. For example, codeclimate would be the host domain of the following URL: http://codeclimate.lighthouseapp.com/projects/123456-code-climate/overview
  2. In a new browser window, navigate to your Code Climate Dashboard.
  3. Mouse over your repository's name and click Settings.
637
  1. Select the Integrations tab.
  2. Next to Lighthouse, click Set Up.
799
  1. Paste the subdomain into the Subdomain field.
  2. Generate your API token. Back in Lighthouse click your user name or avatar in the top-right of the page.
532
  1. Under the Create An API Token section select the account of the project you would like Code Climate to post to.
  2. Enter a name for your token.
  3. Select the project you would like Code Climate to post to.
322

Note: Ensure the token is set to full access.

  1. Click CREATE.

  2. Copy the API token you just generated.

  3. Back in Code Climate, paste the API token into the API Token field.

  4. Locate your Project ID. In Lighthouse, this can be found in any URL while viewing your Lighthouse project. Copy the digits just following the projects/. For example, 123456 would be the project ID of the following URL: http://codeclimate.lighthouseapp.com/projects/123456-code-climate/overview

  5. Back in Code Climate, paste the project ID into the Project field.

  6. Enter any labels in the Labels field. These labels will be associated with any tickets created by Code Climate.

493
  1. Ensure Active is checked and click Save.

  2. To verify the Lighthouse data is valid, click Test Service (this will post a test ticket to your project). If a green message appears at the top of the screen, all is well. If a red error message is displayed, see Troubleshooting below.

701 684

Troubleshooting

If you are seeing a red error message after clicking Test Service:

  • Ensure there are no leading or trailing spaces around any of the input fields that you provided to Code Climate.

  • Ensure your subdomain does not contain any slashes, dots, or prefixes (e.g., "/",".","http://").

  • Ensure your project ID is taken from a project page URL, not from your user account page.