Looker Extension CICD with GitHub Actions

I recently worked on a project to build a looker extension for a french company. Now if you have building looker extensions with the looker extension framework, you would realize it becomes mundane to have to copy your build file into looker and then make a commit in looker before your app can be live in your looker instance. And if you happen to be more than one person working on the team, why not have a process where once is reviewed and merged, the application is updated on looker seamlessly? In this article, I am going to show you how I automated our looker extension deployment. To get started first the Prerequisites

Prerequisites Github Repository This article focuses on using GitHub actions to automate the deployment of looker extensions so apparently you need to have GitHub, so your looker extension code needs to be hosted on GitHub.

Connect Looker to Git repository Your LookML project needs to be connected to an external git repository. Looker can connect to any git provider that allows HTTPS or ssh connection, For this article, we will use GitHub. If your looker project isn't connected to a repository

You need to have admin access on both your extension and lookML repository to the GitHub repository to configure GitHub actions and webhook

Great! In this article, I will guide you through the process of automating the deployment of your Looker extension with GitHub Actions. If you've built a Looker extension before, you'll know that it can be tedious to manually copy your build file into Looker and commit it before it can go live on your Looker instance. By automating the deployment process, you can ensure that your application is updated seamlessly once it's been reviewed and merged.

To get started, there are a few prerequisites you'll need:

  1. A GitHub repository: This article focuses on using GitHub actions to automate the deployment of Looker extensions, so your Looker extension code needs to be hosted on GitHub.

  2. Connect Looker to your Git repository: Your LookML project needs to be connected to an external git repository. Looker can connect to any git provider that allows HTTPS or SSH connection, and for this article, we will use Github. If your Looker project isn't connected to a repository yet, you'll need to set that up first.

Once you have these prerequisites in place, you can move on to setting up your basic Looker extension framework app and pushing it to Github. Here's a brief overview of the steps involved:

  1. Set up your Looker extension framework app: If you're not familiar with the Looker extension framework, you can find more information in the Looker documentation. Once you've set up your app, you'll need to build it.

  2. Push your app to Github: Once you've built your app, you'll need to push it to Github. Make sure you commit any changes you've made to your LookML files and any other relevant files.

Now that you have your basic Looker extension app set up and pushed to Github, you can start setting up GitHub Actions to automate the deployment process. Here's an overview of the steps involved:

  1. Create a Github Action for Github: Github Actions are workflows that you can set up to automate tasks in your Github repository. You'll need to create a Github Action that will build your Looker extension and deploy it to your Looker instance.

  2. Create a GitHub Action for Azure DevOps: If your Looker instance is hosted on Azure DevOps, you'll need to create a Github Action that can deploy your Looker extension to Azure DevOps.

  3. Add a webhook on Github: Once you've set up your Github Actions, you'll need to add a webhook on Github that will trigger your Github Actions when changes are made to your repository.

By following these steps, you can automate the deployment of your Looker extension with GitHub Actions. This will save you time and effort, and ensure that your Looker extension is always up-to-date and ready to go