Skip to content
You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
terminal

GitHub Action

setup-stackql

v1.1.0-beta Pre-release

setup-stackql

terminal

setup-stackql

Sets up the StackQL CLI in your GitHub Actions workflow

Installation

Copy and paste the following snippet into your .yml file.

              

- name: setup-stackql

uses: stackql/[email protected]

Learn more about this action in stackql/setup-stackql

Choose a version

Setup StackQL

setup-stackql

The stackql/setup-stackql action is a JavaScript action that sets up StackQL CLI in your GitHub Actions workflow by:

  • Downloading a latest Stackql CLI and adding it to the PATH.
  • Setup AUTH env var in the Github Action

This action can be run on ubuntu-latest, windows-latest, and macos-latest GitHub Actions runners, and will install and expose the latest version of the stackql CLI on the runner environment.

Auth

Learn more about authentication setup when running stackql

Basic Example

  1. Set Auth variable, for example:
{ "github": { "type": "basic", "credentialsenvvar": "STACKQL_GITHUB_CREDS" } }
  1. create the github token as a secret
  2. In the execution step, pass the secret as environment variable with name "STACKQL_GITHUB_CREDS"

Check the "Use GitHub Provider" step in .github/workflows/setup-stackql.yml for the working example

json File Auth example

  1. Set Auth variable, for example:
{ "google": { "type": "service_account",  "credentialsfilepath": "sa-key.json" }}
  1. encode the key json file into base64 string
  2. in execution step, run sudo echo ${{ secrets.<name of the secret> }} | base64 -d > sa-key.json

Check the "Use Google Provider" step in .github/workflows/setup-stackql.yml for the working example