-
Notifications
You must be signed in to change notification settings - Fork 114
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1,359 changed files
with
362,907 additions
and
96,421 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
node_modules | ||
npm-debug.log | ||
Dockerfile | ||
.dockerignore | ||
.git | ||
.gitignore | ||
docker-compose.yml | ||
buildspec.yml | ||
appspec.yml | ||
* | ||
!src | ||
!Makefile | ||
!jest*.js | ||
!benchmark | ||
!package*.json | ||
!tsconfig.json | ||
!test | ||
!scripts/skipPrepareScript.js | ||
!swagger |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,23 @@ | ||
node_modules/ | ||
.husky/ | ||
reports/ | ||
test/ | ||
benchmark/ | ||
dist/ | ||
**/warehouse/ | ||
**/lambda/ | ||
**/openfaas/ | ||
*.md | ||
*.test.js | ||
test/**/*.js | ||
*.test.ts | ||
src/util/lodash-es-core.js | ||
**/ivm*.js | ||
**/custom*.js | ||
**/warehouse/ | ||
**/lambda/ | ||
**/openfaas/ | ||
src/util/url-search-params.min.js | ||
src/logger.js | ||
src/util/eventValidations.js | ||
**/trackingPlan* | ||
src/v0/destinations/personalize/scripts/ | ||
test/integrations/destinations/testTypes.d.ts | ||
*.config*.js | ||
scripts/skipPrepareScript.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: 'github-actions' | ||
directory: '/' | ||
schedule: | ||
interval: 'weekly' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
name: Build Artifacts for PRs | ||
|
||
on: | ||
pull_request: | ||
types: | ||
- opened | ||
- reopened | ||
- synchronize | ||
|
||
jobs: | ||
generate-tag-names: | ||
runs-on: ubuntu-latest | ||
name: Generate Tag Names | ||
# Skip for the release pull requests as staging artifacts will be generated | ||
if: startsWith(github.event.pull_request.head.ref, 'release/') != true && startsWith(github.event.pull_request.head.ref, 'hotfix-release/') != true && github.event.pull_request.head.ref != 'main' | ||
outputs: | ||
tag_name: ${{ steps.gen_tag_names.outputs.tag_name }} | ||
tag_name_ut: ${{ steps.gen_tag_names.outputs.tag_name_ut }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
with: | ||
fetch-depth: 1 | ||
|
||
# Replace problematic characters in branch name (like '/') with safe characters (like '.') | ||
- name: Generate Tag Names | ||
id: gen_tag_names | ||
run: | | ||
tag_name=$(echo ${{ github.head_ref }} | tr "/" .) | ||
echo "Tag Name: $tag_name" | ||
echo "tag_name=$tag_name" >> $GITHUB_OUTPUT | ||
tag_name_ut="ut-$tag_name" | ||
echo "UT Tag Name: $tag_name_ut" | ||
echo "tag_name_ut=$tag_name_ut" >> $GITHUB_OUTPUT | ||
build-transformer-image: | ||
name: Build Transformer Docker Image - PR | ||
# Skip for the release pull requests as staging artifacts will be generated | ||
# Skip main to develop sync pull requests | ||
if: startsWith(github.event.pull_request.head.ref, 'release/') != true && startsWith(github.event.pull_request.head.ref, 'hotfix-release/') != true && github.event.pull_request.head.ref != 'main' | ||
needs: [generate-tag-names] | ||
uses: ./.github/workflows/build-push-docker-image.yml | ||
with: | ||
build_tag: rudderstack/develop-rudder-transformer:${{ needs.generate-tag-names.outputs.tag_name }} | ||
push_tags: rudderstack/develop-rudder-transformer:${{ needs.generate-tag-names.outputs.tag_name }} | ||
img_tag: ${{ needs.generate-tag-names.outputs.tag_name }} | ||
dockerfile: Dockerfile | ||
load_target: development | ||
push_target: production | ||
secrets: | ||
DOCKERHUB_PROD_TOKEN: ${{ secrets.DOCKERHUB_PROD_TOKEN }} | ||
|
||
build-user-transformer-image: | ||
name: Build User Transformer Docker Image - PR | ||
# Skip for the release pull requests as staging artifacts will be generated | ||
if: startsWith(github.event.pull_request.head.ref, 'release/') != true && startsWith(github.event.pull_request.head.ref, 'hotfix-release/') != true && github.event.pull_request.head.ref != 'main' | ||
needs: [generate-tag-names] | ||
uses: ./.github/workflows/build-push-docker-image.yml | ||
with: | ||
build_tag: rudderstack/develop-rudder-transformer:${{ needs.generate-tag-names.outputs.tag_name_ut }} | ||
push_tags: rudderstack/develop-rudder-transformer:${{ needs.generate-tag-names.outputs.tag_name_ut }} | ||
img_tag: ${{ needs.generate-tag-names.outputs.tag_name_ut }} | ||
dockerfile: Dockerfile-ut-func | ||
load_target: development | ||
push_target: production | ||
secrets: | ||
DOCKERHUB_PROD_TOKEN: ${{ secrets.DOCKERHUB_PROD_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,149 @@ | ||
name: Build Transformer Docker Image | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
build_tag: | ||
required: true | ||
type: string | ||
push_tags: | ||
required: true | ||
type: string | ||
img_tag: | ||
required: true | ||
type: string | ||
dockerfile: | ||
required: true | ||
type: string | ||
load_target: | ||
required: true | ||
type: string | ||
push_target: | ||
required: true | ||
type: string | ||
secrets: | ||
DOCKERHUB_PROD_TOKEN: | ||
required: true | ||
|
||
env: | ||
DOCKERHUB_USERNAME: rudderlabs | ||
|
||
jobs: | ||
build-transformer-image-arm64: | ||
name: Build Transformer Docker Image ARM64 | ||
runs-on: [self-hosted, Linux, ARM64] | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
with: | ||
fetch-depth: 1 | ||
|
||
- name: Setup Docker Buildx | ||
uses: docker/[email protected] | ||
|
||
- name: Login to DockerHub | ||
uses: docker/[email protected] | ||
with: | ||
username: ${{ env.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_PROD_TOKEN }} | ||
|
||
- name: Build Docker Image | ||
uses: docker/[email protected] | ||
with: | ||
context: . | ||
file: ${{ inputs.dockerfile }} | ||
target: ${{ inputs.load_target }} | ||
load: true | ||
tags: ${{ inputs.build_tag }} | ||
# cache-from: type=gha | ||
# cache-to: type=gha,mode=max | ||
|
||
- name: Run Tests | ||
run: | | ||
docker run ${{ inputs.build_tag }} npm run test:js:ci | ||
docker run ${{ inputs.build_tag }} npm run test:ts:ci | ||
- name: Build and Push Multi-platform Images | ||
uses: docker/[email protected] | ||
with: | ||
context: . | ||
file: ${{ inputs.dockerfile }} | ||
target: ${{ inputs.push_target }} | ||
push: true | ||
tags: ${{ inputs.push_tags }}-arm64 | ||
platforms: | | ||
linux/arm64 | ||
build-args: | | ||
version=${{ inputs.img_tag }}-arm64 | ||
GIT_COMMIT_SHA=${{ github.sha }} | ||
# cache-from: type=gha | ||
# cache-to: type=gha,mode=max | ||
|
||
build-transformer-image-amd64: | ||
name: Build Transformer Docker Image AMD64 | ||
runs-on: [self-hosted, Linux, X64] | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
with: | ||
fetch-depth: 1 | ||
|
||
- name: Setup Docker Buildx | ||
uses: docker/[email protected] | ||
|
||
- name: Login to DockerHub | ||
uses: docker/[email protected] | ||
with: | ||
username: ${{ env.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_PROD_TOKEN }} | ||
|
||
- name: Build Docker Image | ||
uses: docker/[email protected] | ||
with: | ||
context: . | ||
file: ${{ inputs.dockerfile }} | ||
target: ${{ inputs.load_target }} | ||
load: true | ||
tags: ${{ inputs.build_tag }} | ||
# cache-from: type=gha | ||
# cache-to: type=gha,mode=max | ||
|
||
- name: Run Tests | ||
run: | | ||
docker run ${{ inputs.build_tag }} npm run test:js:ci | ||
docker run ${{ inputs.build_tag }} npm run test:ts:ci | ||
- name: Build and Push Multi-platform Images | ||
uses: docker/[email protected] | ||
with: | ||
context: . | ||
file: ${{ inputs.dockerfile }} | ||
target: ${{ inputs.push_target }} | ||
push: true | ||
tags: ${{ inputs.push_tags }}-amd64 | ||
platforms: | | ||
linux/amd64 | ||
build-args: | | ||
version=${{ inputs.img_tag }}-amd64 | ||
GIT_COMMIT_SHA=${{ github.sha }} | ||
# cache-from: type=gha | ||
# cache-to: type=gha,mode=max | ||
|
||
create-manifest: | ||
name: Create multi-arch manifest | ||
runs-on: ubuntu-latest | ||
needs: [build-transformer-image-amd64, build-transformer-image-arm64] | ||
|
||
steps: | ||
- name: Set up Docker Buildx | ||
uses: docker/[email protected] | ||
|
||
- name: Login to DockerHub | ||
uses: docker/[email protected] | ||
with: | ||
username: ${{ env.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_PROD_TOKEN }} | ||
|
||
- name: Create multi-arch manifest | ||
run: | | ||
docker buildx imagetools create -t ${{ inputs.push_tags }} ${{ inputs.push_tags }}-amd64 ${{ inputs.push_tags }}-arm64 |
Oops, something went wrong.