Skip to content

Commit 75621b7

Browse files
authored
Merge branch 'main' into feat/revoke-invite
2 parents dd34638 + 61c9a7c commit 75621b7

File tree

690 files changed

+40862
-8467
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

690 files changed

+40862
-8467
lines changed

.env.example

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ NODE_ENV=development
3131
# FROM_EMAIL=
3232
# REPLY_TO_EMAIL=
3333

34+
# Remove the following line to enable logging telemetry traces to the console
35+
LOG_TELEMETRY="false"
36+
3437
# CLOUD VARIABLES
3538
POSTHOG_PROJECT_KEY=
3639
PLAIN_API_KEY=
@@ -42,4 +45,18 @@ CLOUD_LINEAR_CLIENT_ID=
4245
CLOUD_LINEAR_CLIENT_SECRET=
4346
CLOUD_SLACK_APP_HOST=
4447
CLOUD_SLACK_CLIENT_ID=
45-
CLOUD_SLACK_CLIENT_SECRET=
48+
CLOUD_SLACK_CLIENT_SECRET=
49+
50+
# v3 variables
51+
PROVIDER_SECRET=provider-secret # generate the actual secret with `openssl rand -hex 32`
52+
COORDINATOR_SECRET=coordinator-secret # generate the actual secret with `openssl rand -hex 32`
53+
54+
# Uncomment the following line to enable the registry proxy
55+
# ENABLE_REGISTRY_PROXY=true
56+
# DEPOT_TOKEN=<Depot org token>
57+
# DEPOT_PROJECT_ID=<Depot project id>
58+
# DEPLOY_REGISTRY_HOST=${APP_ORIGIN} # This is the host that the deploy CLI will use to push images to the registry
59+
# CONTAINER_REGISTRY_ORIGIN=<Container registry origin e.g. https://registry.digitalocean.com>
60+
# CONTAINER_REGISTRY_USERNAME=<Container registry username e.g. Digital ocean email address>
61+
# CONTAINER_REGISTRY_PASSWORD=<Container registry password e.g. Digital ocean PAT>
62+
# DEV_OTEL_EXPORTER_OTLP_ENDPOINT="http://0.0.0.0:4318"
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: OpenTelemetry Auto-Instrumentation Request
2+
description: Suggest an SDK that you'd like to be auto-instrumented in the Run log view
3+
title: "auto-instrumentation: "
4+
labels: ["🌟 enhancement"]
5+
body:
6+
- type: textarea
7+
attributes:
8+
label: What API or SDK would you to have automatic spans for?
9+
description: A clear description of which API or SDK you'd like, and links to it.
10+
validations:
11+
required: true
12+
- type: textarea
13+
attributes:
14+
label: Is there an existing OpenTelemetry auto-instrumentation package?
15+
description: You can search for existing ones – https://opentelemetry.io/ecosystem/registry/?component=instrumentation&language=js
16+
validations:
17+
required: true
18+
- type: textarea
19+
attributes:
20+
label: Additional information
21+
description: Add any other information related to the feature here. If your feature request is related to any issues or discussions, link them here.

.github/workflows/e2e.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,13 @@ on:
44
jobs:
55
e2e:
66
name: "🧪 E2E Tests"
7-
runs-on: buildjet-4vcpu-ubuntu-2204
7+
runs-on: buildjet-16vcpu-ubuntu-2204
88
steps:
99
- name: 🐳 Login to Docker Hub
10-
if: github.event_name == 'push'
1110
uses: docker/login-action@v2
1211
with:
13-
username: ${{ secrets.DOCKERHUB_USERNAME }}
14-
password: ${{ secrets.DOCKERHUB_TOKEN }}
12+
username: ${{ secrets.DOCKERHUB_USERNAME || vars.DOCKERHUB_USERNAME }}
13+
password: ${{ secrets.DOCKERHUB_TOKEN || vars.DOCKERHUB_TOKEN }}
1514

1615
- name: ⬇️ Checkout repo
1716
uses: actions/checkout@v3
@@ -32,6 +31,8 @@ jobs:
3231

3332
- name: Install Protoc
3433
uses: arduino/setup-protoc@v3
34+
with:
35+
repo-token: ${{ secrets.GITHUB_TOKEN }}
3536

3637
- name: 📥 Download deps
3738
run: pnpm install --frozen-lockfile

.github/workflows/publish-dev.yml

Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
name: "🚢 Publish Container Images (dev)"
2+
3+
on:
4+
push:
5+
tags:
6+
- "dev-*"
7+
paths:
8+
- ".github/workflows/publish.yml"
9+
- "packages/**"
10+
- "!packages/**/*.md"
11+
- "!packages/**/*.eslintrc"
12+
- "apps/**"
13+
- "!apps/**/*.md"
14+
- "!apps/**/*.eslintrc"
15+
- "integrations/**"
16+
- "!integrations/**/*.md"
17+
- "!integrations/**/*.eslintrc"
18+
- "pnpm-lock.yaml"
19+
- "pnpm-workspace.yaml"
20+
- "turbo.json"
21+
- "docker/Dockerfile"
22+
- "docker/scripts/**"
23+
- "tests/**"
24+
25+
permissions:
26+
id-token: write
27+
packages: write
28+
contents: read
29+
30+
concurrency:
31+
group: ${{ github.workflow }}-${{ github.ref }}
32+
33+
env:
34+
AWS_REGION: us-east-1
35+
36+
jobs:
37+
build:
38+
strategy:
39+
matrix:
40+
package: [coordinator, kubernetes-provider]
41+
runs-on: buildjet-16vcpu-ubuntu-2204
42+
env:
43+
DOCKER_BUILDKIT: "1"
44+
steps:
45+
- uses: actions/checkout@v4
46+
47+
- name: Generate build ID
48+
id: prep
49+
run: |
50+
sha=${GITHUB_SHA::7}
51+
ts=$(date +%s)
52+
echo "BUILD_ID=${{ matrix.package }}-${sha}-${ts}" >> "$GITHUB_OUTPUT"
53+
54+
- name: Set up Docker Buildx
55+
uses: docker/setup-buildx-action@v3
56+
57+
# ..to avoid rate limits when pulling images
58+
- name: Login to DockerHub
59+
uses: docker/login-action@v3
60+
with:
61+
username: ${{ secrets.DOCKERHUB_USERNAME }}
62+
password: ${{ secrets.DOCKERHUB_TOKEN }}
63+
64+
- name: 🚢 Build Container Image
65+
run: |
66+
docker build -t dev_image -f ./apps/${{ matrix.package }}/Containerfile .
67+
68+
# ..to push image
69+
- name: 🐙 Login to GitHub Container Registry
70+
uses: docker/login-action@v3
71+
with:
72+
registry: ghcr.io
73+
username: ${{ github.repository_owner }}
74+
password: ${{ secrets.GITHUB_TOKEN }}
75+
76+
- name: 🐙 Push to GitHub Container Registry
77+
run: |
78+
docker tag dev_image $REGISTRY/$REPOSITORY:$IMAGE_TAG
79+
docker push $REGISTRY/$REPOSITORY:$IMAGE_TAG
80+
env:
81+
REGISTRY: ghcr.io/triggerdotdev
82+
REPOSITORY: dev
83+
IMAGE_TAG: ${{ steps.prep.outputs.BUILD_ID }}

.github/workflows/publish-docker.yml

Lines changed: 12 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,14 @@ on:
33
workflow_call:
44
jobs:
55
publish:
6-
strategy:
7-
fail-fast: true # when a job fails, all remaining ones will be cancelled
8-
matrix:
9-
runs-on: [buildjet-4vcpu-ubuntu-2204, buildjet-4vcpu-ubuntu-2204-arm]
10-
name: ${{matrix.runs-on}}
11-
runs-on: ${{matrix.runs-on}}
6+
runs-on: ubuntu-latest
127
outputs:
138
version: ${{ steps.get_version.outputs.version }}
149
short_sha: ${{ steps.get_commit.outputs.sha_short }}
1510
steps:
16-
- name: 🐳 Login to Docker Hub
17-
uses: docker/login-action@v2
18-
with:
19-
username: ${{ secrets.DOCKERHUB_USERNAME }}
20-
password: ${{ secrets.DOCKERHUB_TOKEN }}
11+
- name: Setup Depot CLI
12+
uses: depot/setup-action@v1
13+
2114
- name: ⬇️ Checkout repo
2215
uses: actions/checkout@v3
2316
with:
@@ -43,44 +36,24 @@ jobs:
4336
echo "Invalid reference: ${GITHUB_REF}"
4437
exit 1
4538
fi
46-
if [[ ${{matrix.runs-on}} == *-arm ]]; then
47-
IMAGE_TAG="${IMAGE_TAG}-arm"
48-
fi
4939
echo "::set-output name=version::${IMAGE_TAG}"
5040
- name: 🔢 Get the commit hash
5141
id: get_commit
5242
run: |
5343
echo ::set-output name=sha_short::$(echo ${{ github.sha }} | cut -c1-7)
5444
55-
- name: 🐳 Build Docker Image
56-
run: |
57-
docker build -t release_build_image -f ./docker/Dockerfile .
58-
5945
- name: 🐙 Login to GitHub Container Registry
6046
uses: docker/login-action@v2
6147
with:
6248
registry: ghcr.io
6349
username: ${{ github.repository_owner }}
6450
password: ${{ secrets.GITHUB_TOKEN }}
6551

66-
- name: 🐙 Push to GitHub Container Registry
67-
run: |
68-
docker tag release_build_image $REGISTRY/$REPOSITORY:$IMAGE_TAG
69-
docker push $REGISTRY/$REPOSITORY:$IMAGE_TAG
70-
env:
71-
REGISTRY: ghcr.io/triggerdotdev
72-
REPOSITORY: trigger.dev
73-
IMAGE_TAG: ${{ steps.get_version.outputs.version }}
74-
75-
- name: 🐙 Push 'latest' to GitHub Container Registry
76-
if: startsWith(github.ref, 'refs/tags/v.docker')
77-
run: |
78-
LATEST=latest
79-
if [[ ${{matrix.runs-on}} == *-arm ]]; then
80-
LATEST="${LATEST}-arm"
81-
fi
82-
docker tag release_build_image $REGISTRY/$REPOSITORY:$LATEST
83-
docker push $REGISTRY/$REPOSITORY:$LATEST
84-
env:
85-
REGISTRY: ghcr.io/triggerdotdev
86-
REPOSITORY: trigger.dev
52+
- name: 🐳 Build image and push to GitHub Container Registry
53+
uses: depot/build-push-action@v1
54+
with:
55+
file: ./docker/Dockerfile
56+
platforms: linux/amd64,linux/arm64
57+
tags: |
58+
ghcr.io/triggerdotdev/trigger.dev:${{ steps.get_version.outputs.version }}
59+
push: true

.github/workflows/release.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ on:
1212
jobs:
1313
release:
1414
name: 🦋 Changesets Release
15-
runs-on: buildjet-4vcpu-ubuntu-2204
15+
runs-on: buildjet-16vcpu-ubuntu-2204
1616
if: |
1717
github.repository == 'triggerdotdev/trigger.dev'
1818
outputs:
@@ -40,6 +40,8 @@ jobs:
4040

4141
- name: Install Protoc
4242
uses: arduino/setup-protoc@v3
43+
with:
44+
repo-token: ${{ secrets.GITHUB_TOKEN }}
4345

4446
- name: 📥 Download deps
4547
run: pnpm install --frozen-lockfile

.github/workflows/typecheck.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ on:
33
workflow_call:
44
jobs:
55
typecheck:
6-
runs-on: buildjet-4vcpu-ubuntu-2204
6+
runs-on: buildjet-16vcpu-ubuntu-2204
77

88
steps:
99
- name: ⬇️ Checkout repo
@@ -24,6 +24,8 @@ jobs:
2424

2525
- name: Install Protoc
2626
uses: arduino/setup-protoc@v3
27+
with:
28+
repo-token: ${{ secrets.GITHUB_TOKEN }}
2729

2830
- name: 📥 Download deps
2931
run: pnpm install --frozen-lockfile

.github/workflows/unit-tests.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ on:
44
jobs:
55
unitTests:
66
name: "🧪 Unit Tests"
7-
runs-on: buildjet-4vcpu-ubuntu-2204
7+
runs-on: buildjet-16vcpu-ubuntu-2204
88
steps:
99
- name: ⬇️ Checkout repo
1010
uses: actions/checkout@v3
@@ -24,6 +24,8 @@ jobs:
2424

2525
- name: Install Protoc
2626
uses: arduino/setup-protoc@v3
27+
with:
28+
repo-token: ${{ secrets.GITHUB_TOKEN }}
2729

2830
- name: ⎔ Setup Deno
2931
uses: denoland/setup-deno@v1

.vscode/launch.json

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"request": "launch",
1010
"name": "Debug WebApp",
1111
"command": "pnpm run dev --filter webapp",
12-
"envFile": "${workspaceFolder}/apps/webapp/.env",
12+
"envFile": "${workspaceFolder}/.env",
1313
"cwd": "${workspaceFolder}",
1414
"sourceMaps": true
1515
},
@@ -33,9 +33,25 @@
3333
"type": "node-terminal",
3434
"request": "launch",
3535
"name": "Debug V3 Dev CLI",
36-
"command": "pnpm exec trigger.dev dev",
36+
"command": "pnpm exec trigger.dev dev --log-level debug",
3737
"cwd": "${workspaceFolder}/references/v3-catalog",
3838
"sourceMaps": true
39+
},
40+
{
41+
"type": "node-terminal",
42+
"request": "launch",
43+
"name": "Debug V3 Deploy CLI",
44+
"command": "pnpm exec trigger.dev deploy",
45+
"cwd": "${workspaceFolder}/references/v3-catalog",
46+
"sourceMaps": true
47+
},
48+
{
49+
"type": "node",
50+
"request": "attach",
51+
"name": "Attach to Trigger.dev CLI (v3)",
52+
"port": 9229,
53+
"restart": true,
54+
"skipFiles": ["<node_internals>/**"]
3955
}
4056
]
4157
}

apps/coordinator/.env.example

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
HTTP_SERVER_PORT=8020
2+
PLATFORM_ENABLED=true
3+
PLATFORM_WS_PORT=3030

apps/coordinator/.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
dist/
2+
node_modules/
3+
.env

0 commit comments

Comments
 (0)