-
Notifications
You must be signed in to change notification settings - Fork 1
36 lines (32 loc) · 863 Bytes
/
amp_deploy.yml
File metadata and controls
36 lines (32 loc) · 863 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Deploy Ampersand Integrations
on:
push:
branches:
- main
paths:
- amp/amp.yml
pull_request:
branches:
- "**"
paths:
- amp/amp.yml
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Deploy to test environment
if: github.event_name == 'pull_request'
uses: amp-labs/cli-action@v1
with:
api_key: ${{ secrets.AMP_DEV_API_KEY }}
project_id: ${{ secrets.AMP_DEV_PROJECT_ID }}
directory_path: "./amp"
- name: Deploy to prod environment
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
uses: amp-labs/cli-action@v1
with:
api_key: ${{ secrets.AMP_PROD_API_KEY }}
project_id: ${{ secrets.AMP_PROD_PROJECT_ID }}
directory_path: "./amp"