# GitHub

## **Configure GitHub Repos in Fylamynt**

* Navigate to **Settings** > **Integrations** > **GitHub Repos > Add Integration**.

Details needed to set up **GitHub Repos** in Fylamynt:

| **Parameter** | **Description**           | **Required**                   |
| ------------- | ------------------------- | ------------------------------ |
| Repo Id       | Repository name           | True                           |
| SSH Key       | SSH key of GitHub account | Either SSH key or Access Token |
| Access Token  | Access token              | Either SSH key or Access Token |
| URL           | GIT repo SSH URL          | True                           |

You can configure Github using either **Access Token** or **SSH key.**

An access token is recommended as you can specify granular level access, while SSH Key gives account level access to the Fylamynt.

* Configure SSH Key:
  * Select “**Profile Icon”** -> “**Settings”** -> “**SSH and GPG keys”**
  * Configure SSH key and add this key as **SSH Key**  parameter in Fylamynt repo configuration
* Configure Access Token:
  * Select “**Profile Icon”** -> “**Settings”** -> “**Developer Settings”** -> **“Personal Access Tokens”**
  * Configure Access Token and this as **Access Token** parameter in Fylamynt repo configuration

## **Integration Actions**

Configured GitHub repos can be used as input for any other actions like **CloudFormation\_Run\_Template.** This action node fetches the CloudFormation template file from the GitHub repo and executes it with given parameters.

Configure CloudFormation Template:

* Make sure that GitHub repos are already configured
* Navigate to **Settings** > **Resources** > **CloudFormation Templates > Add New**.
* Add the following details:

| **Parameter** | **Description**                      | **Required** |
| ------------- | ------------------------------------ | ------------ |
| Template Id   | Name for the CloudFormation Template | True         |
| Repo Id       | Repo in which CF template is present | True         |
| FilePath      | Path to CF template in the repo      | True         |
| Ref           | Branch, tag, or commit to checkout   | True         |

* Click on **Save CloudFormation Template**

Now this template is available in the **CloudFormation\_Run\_Template** node.
