This guide provides a comprehensive walkthrough for integrating Factory with your GitHub Enterprise Server (GHES) instance. This integration enables Factory’s Droids to securely access and work with your on-premise repositories.

Prerequisites

  • Admin access to your GitHub Enterprise Server instance
  • Network access between your GHES instance and Factory’s AWS VPC
  • A Factory account with admin privileges

Integration Process

1

Initial Setup & Information Gathering

1

Create GitHub App

  1. Navigate to your GHES instance settings.
  2. Go to GitHub Apps and click “New GitHub App”.
  3. Fill in the app details:
    • Name: “Factory Integration”
    • Homepage URL: https://factory.ai
    • Webhook URL: (Provided by Factory)
  4. Set permissions as outlined in the “Required Permissions” section below.
  5. Generate and securely store a private key for the app.
2

Collect Integration Information

Gather the following details:

  • GitHub App ID
  • Client ID
  • Client Secret
  • Webhook Secret
  • Private Key (generated in previous step)
  • Your GHES instance hostname
3

Submit Information to Factory

Securely send the collected information to your Factory representative.

2

Network Security Configuration

1

Evaluate Network Policy

Review your current network security policies to identify potential connectivity barriers with Factory’s AWS VPC.

2

Establish Connectivity

Choose one of the following methods:

  1. VPC Peering (if your GHES is on AWS):
    • Initiate a VPC peering request.
    • Exchange VPC IDs with Factory.
    • Configure route tables for direct network routes.
  2. VPN Connection:
    • Establish a VPN between your network and Factory’s.
    • Ensure VPN settings (e.g., IPsec) are compatible on both ends.
3

Firewall Configuration

  • Allow outbound connections to Factory’s services (HTTPS and SSH traffic).
  • Ensure your GHES instance can communicate with the Factory-provided Lambda function URL.
3

Webhook Setup

Configure the webhook in your GHES to send events to the Factory-provided cloud function URL.

4

Required Permissions

Ensure the GitHub App has the following permissions:

  • Actions and Metadata (Read)
  • Code (Read & Write)
  • Commit Statuses (Read & Write)
  • Discussions (Read & Write)
  • Issues (Read & Write)
  • Pull Requests (Read & Write)
  • Workflows (Read & Write)
5

Testing and Validation

1

Preliminary Testing

Work with Factory to conduct initial tests of webhook connectivity and data exchange.

2

Comprehensive Testing

Test all GitHub events that trigger Droids within Factory, including:

  • Creating pull requests
  • Pushing code
  • Opening issues
3

Validation

Verify that Factory Droids respond correctly to these events.

6

Final Adjustments and Go-Live

1

Feedback and Adjustments

Provide feedback on any issues encountered during testing. Work with Factory to make necessary adjustments.

2

Go-Live

Agree on a go-live date with Factory.

3

Monitoring

Implement continuous monitoring for the initial days post-launch to quickly address any unforeseen issues.

Troubleshooting

  • If webhook events aren’t being received, check your network configuration and firewall rules.
  • For permission-related issues, review the GitHub App settings in your GHES instance.
  • If Droids aren’t responding as expected, verify that all required events are being sent and that permissions are correctly set.

Support

For any specific issues or detailed support needs, contact the Factory team through your designated support channel.

Security and Compliance

Learn about Factory’s security measures for enterprise integrations