-
Notifications
You must be signed in to change notification settings - Fork 5
64 lines (61 loc) · 1.92 KB
/
feature-flags.yml
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: Feature Flags
on:
pull_request:
paths:
- 'infrastructure/feature-flags/**'
- 'packages/**'
- 'servers/feature-flags/**'
- 'pnpm-lock.yaml'
- 'Dockerfile'
- '.github/actions/**'
- '.github/workflows/feature-flags.yml'
- '.github/workflows/reuse-*.yml'
push:
branches:
- main
- dev
paths:
- 'infrastructure/feature-flags/**'
- 'packages/**'
- 'servers/feature-flags/**'
- 'pnpm-lock.yaml'
- 'Dockerfile'
- '.github/actions/**'
- '.github/workflows/feature-flags.yml'
- '.github/workflows/reuse-*.yml'
jobs:
apollo:
uses: ./.github/workflows/reuse-apollo-federation.yml
with:
federated-graph-name: pocket-client-api
graph-name: featureflags
schema-file-path: servers/feature-flags/schema.graphql
prod-graph-url: https://featureflags.readitlater.com/graphql
dev-graph-url: https://featureflags.getpocket.dev/graphql
secrets:
apollo-key: ${{ secrets.APOLLO_CLIENT_API_KEY }}
infrastructure:
uses: ./.github/workflows/reuse-infrastructure.yml
with:
scope: feature-flags-cdk
stack-output-path: infrastructure/feature-flags/cdktf.out/stacks/feature-flags
secrets: inherit
api:
uses: ./.github/workflows/reuse-build-and-push-image.yml
needs: [infrastructure]
with:
scope: feature-flags
app-path: servers/feature-flags
app-port: 4242
sentry-project: feature-flags
docker-repo-name-pattern: featureflags-{0}-app
terraform-output: ${{needs.infrastructure.outputs.terraform-output}}
secrets: inherit
sentry:
if: github.ref == 'refs/heads/dev' || github.ref == 'refs/heads/main'
uses: ./.github/workflows/reuse-sentry-release.yml
needs: [api]
with:
sentry-project: feature-flags
sentry-environment: ${{ github.ref == 'refs/heads/main' && 'production' || 'development' }}
secrets: inherit