Skip to content

Commit

Permalink
preparing for git move
Browse files Browse the repository at this point in the history
Signed-off-by: vaidikcode <vaidikbhardwaj00@gmail.com>
  • Loading branch information
vaidikcode committed Dec 4, 2024
1 parent cf3303f commit d696440
Show file tree
Hide file tree
Showing 9 changed files with 516 additions and 0 deletions.
53 changes: 53 additions & 0 deletions .github/workflows/ci-crossdock.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: CIT Crossdock

on:
push:
branches: [main]

pull_request:
branches: [main]

concurrency:
group: ${{ github.workflow }}-${{ (github.event.pull_request && github.event.pull_request.number) || github.ref || github.run_id }}
cancel-in-progress: true

# See /~https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions
permissions:
contents: read

jobs:
crossdock:
runs-on: ubuntu-latest

steps:
- uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
with:
egress-policy: audit # TODO: change to 'egress-policy: block' after couple of runs

- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0
with:
submodules: true

- name: Fetch git tags
run: |
git fetch --prune --unshallow --tags
- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version: 1.23.x

- uses: ./.github/actions/setup-branch

- run: make install-ci

- uses: docker/setup-qemu-action@49b3bc8e6bdd4a60e6116a5414239cba5943d3cf # v3.2.0

- name: Build, test, and publish crossdock image
run: bash scripts/build-crossdock.sh
env:
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
QUAY_TOKEN: ${{ secrets.QUAY_TOKEN }}

- name: Output crossdock logs
run: make crossdock-logs
if: ${{ failure() }}
78 changes: 78 additions & 0 deletions .github/workflows/ci-docker-hotrod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
name: CIT Hotrod

on:
push:
branches: [main]

pull_request:
branches: [main]

concurrency:
group: ${{ github.workflow }}-${{ (github.event.pull_request && github.event.pull_request.number) || github.ref || github.run_id }}
cancel-in-progress: true

# See /~https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions
permissions:
contents: read

jobs:
hotrod:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
runtime: [docker, k8s]
jaeger-version: [v1, v2]

steps:
- uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
with:
egress-policy: audit # TODO: change to 'egress-policy: block' after couple of runs

- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0
with:
submodules: true

- name: Fetch git tags
run: |
git fetch --prune --unshallow --tags
- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version: 1.23.x

- uses: ./.github/actions/setup-node.js

- uses: ./.github/actions/setup-branch

- uses: docker/setup-qemu-action@49b3bc8e6bdd4a60e6116a5414239cba5943d3cf # v3.2.0

- name: Define BUILD_FLAGS var if running on a Pull Request
run: |
case ${GITHUB_EVENT_NAME} in
pull_request)
echo "BUILD_FLAGS=-l -p linux/amd64" >> ${GITHUB_ENV}
;;
*)
echo "BUILD_FLAGS=" >> ${GITHUB_ENV}
;;
esac
- name: Install kubectl
if: matrix.runtime == 'k8s'
uses: azure/setup-kubectl@v4
with:
version: 'latest'

- name: Install Kustomize
if: matrix.runtime == 'k8s'
uses: imranismail/setup-kustomize@v2

- name: Create k8s Kind Cluster
if: matrix.runtime == 'k8s'
uses: helm/kind-action@v1

- name: Build, test, and publish hotrod image
run: bash scripts/build-hotrod-image.sh ${{ env.BUILD_FLAGS }} -v ${{ matrix.jaeger-version }} -r ${{ matrix.runtime }}
env:
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
QUAY_TOKEN: ${{ secrets.QUAY_TOKEN }}
52 changes: 52 additions & 0 deletions .github/workflows/ci-e2e-badger.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: CIT Badger

on:
push:
branches: [main]

pull_request:
branches: [main]

concurrency:
group: ${{ github.workflow }}-${{ (github.event.pull_request && github.event.pull_request.number) || github.ref || github.run_id }}
cancel-in-progress: true

# See /~https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions
permissions: # added using /~https://github.com/step-security/secure-workflows
contents: read

jobs:
badger:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
version: [v1, v2]
steps:
- name: Harden Runner
uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
with:
egress-policy: audit # TODO: change to 'egress-policy: block' after couple of runs

- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0

- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version: 1.23.x

- name: Run Badger storage integration tests
run: |
case ${{ matrix.version }} in
v1)
make badger-storage-integration-test
;;
v2)
STORAGE=badger make jaeger-v2-storage-integration-test
;;
esac
- name: Upload coverage to codecov
uses: ./.github/actions/upload-codecov
with:
files: cover.out
flags: badger_${{ matrix.version }}
60 changes: 60 additions & 0 deletions .github/workflows/ci-e2e-cassandra.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: CIT Cassandra

on:
push:
branches: [main]

pull_request:
branches: [main]

concurrency:
group: ${{ github.workflow }}-${{ (github.event.pull_request && github.event.pull_request.number) || github.ref || github.run_id }}
cancel-in-progress: true

# See /~https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions
permissions: # added using /~https://github.com/step-security/secure-workflows
contents: read

jobs:
cassandra:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
jaeger-version: [v1, v2]
create-schema: [manual, auto]
version:
- distribution: cassandra
major: 4.x
schema: v004
- distribution: cassandra
major: 5.x
schema: v004
exclude:
# Exclude v1 as create schema on fly is available for v2 only
- jaeger-version: v1
create-schema: auto
name: ${{ matrix.version.distribution }}-${{ matrix.version.major }} ${{ matrix.jaeger-version }} schema=${{ matrix.create-schema }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
with:
egress-policy: audit # TODO: change to 'egress-policy: block' after couple of runs

- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0

- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version: 1.23.x

- name: Run cassandra integration tests
id: test-execution
run: bash scripts/cassandra-integration-test.sh ${{ matrix.version.major }} ${{ matrix.version.schema }} ${{ matrix.jaeger-version }}
env:
SKIP_APPLY_SCHEMA: ${{ matrix.create-schema == 'auto' && true || false }}

- name: Upload coverage to codecov
uses: ./.github/actions/upload-codecov
with:
files: cover.out
flags: cassandra-${{ matrix.version.major }}-${{ matrix.jaeger-version }}-${{ matrix.create-schema }}
71 changes: 71 additions & 0 deletions .github/workflows/ci-e2e-elasticsearch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
name: CIT Elasticsearch

on:
push:
branches: [main]

pull_request:
branches: [main]

concurrency:
group: ${{ github.workflow }}-${{ (github.event.pull_request && github.event.pull_request.number) || github.ref || github.run_id }}
cancel-in-progress: true

# See /~https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions
permissions: # added using /~https://github.com/step-security/secure-workflows
contents: read

jobs:
elasticsearch:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
version:
- major: 6.x
distribution: elasticsearch
jaeger: v1
- major: 7.x
distribution: elasticsearch
jaeger: v1
- major: 8.x
distribution: elasticsearch
jaeger: v1
- major: 8.x
distribution: elasticsearch
jaeger: v2
name: ${{ matrix.version.distribution }} ${{ matrix.version.major }} ${{ matrix.version.jaeger }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
with:
egress-policy: audit # TODO: change to 'egress-policy: block' after couple of runs

- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0
with:
submodules: true

- name: Fetch git tags
run: |
git fetch --prune --unshallow --tags
- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version: 1.23.x

- name: time settings
run: |
date
echo TZ="$TZ"
- uses: docker/setup-qemu-action@49b3bc8e6bdd4a60e6116a5414239cba5943d3cf # v3.2.0
- name: Run ${{ matrix.version.distribution }} integration tests
id: test-execution
run: bash scripts/es-integration-test.sh ${{ matrix.version.distribution }} ${{ matrix.version.major }} ${{ matrix.version.jaeger }}

- name: Upload coverage to codecov
uses: ./.github/actions/upload-codecov
with:
files: cover.out,cover-index-cleaner.out,cover-index-rollover.out
flags: ${{ matrix.version.distribution }}-${{ matrix.version.major }}-${{ matrix.version.jaeger }}

52 changes: 52 additions & 0 deletions .github/workflows/ci-e2e-grpc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: CIT gRPC

on:
push:
branches: [main]

pull_request:
branches: [main]

concurrency:
group: ${{ github.workflow }}-${{ (github.event.pull_request && github.event.pull_request.number) || github.ref || github.run_id }}
cancel-in-progress: true

# See /~https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions
permissions: # added using /~https://github.com/step-security/secure-workflows
contents: read

jobs:
grpc:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
version: [v1, v2]
steps:
- name: Harden Runner
uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
with:
egress-policy: audit # TODO: change to 'egress-policy: block' after couple of runs

- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0

- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version: 1.23.x

- name: Run gRPC storage integration tests
run: |
case ${{ matrix.version }} in
v1)
SPAN_STORAGE_TYPE=memory make grpc-storage-integration-test
;;
v2)
STORAGE=grpc SPAN_STORAGE_TYPE=memory make jaeger-v2-storage-integration-test
;;
esac
- name: Upload coverage to codecov
uses: ./.github/actions/upload-codecov
with:
files: cover.out
flags: grpc_${{ matrix.version }}
Loading

0 comments on commit d696440

Please sign in to comment.