diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index e1ba948e..f5bb98b7 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -32,7 +32,7 @@ jobs: strategy: fail-fast: false matrix: - language: [ ] + language: [ 'javascript' ] # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ] # Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support diff --git a/.github/workflows/docker-image.yaml b/.github/workflows/docker-image.yaml index c93b6c29..5e842826 100644 --- a/.github/workflows/docker-image.yaml +++ b/.github/workflows/docker-image.yaml @@ -1,35 +1,59 @@ -name: Docker Image CI - +name: ci on: push: - paths-ignore: - - 'charts/**' - - '**.md' - branches: [ main ] + branches: + - 'main' + tags: + - 'v*.*.*' pull_request: - paths-ignore: - - 'helm/**' - - '**.md' - branches: [ main ] + branches: + - 'main' env: - # Use docker.io for Docker Hub if empty - REGISTRY: ghcr.io - # github.repository as / - IMAGE_NAME: ${{ github.repository }} + REGISTRY: ghcr.io + IMAGE: sheril5/quality-trace jobs: - - build: - + docker: runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Build the Docker image - run: docker build . --file Dockerfile --tag ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}/quality-trace:latest - - name: Docker push - run: | - docker login ${{ env.REGISTRY }} -u jebinjeb -p ${{ secrets.GITHUB_TOKEN }} - docker push ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}/quality-trace:latest - if: github.event_name == 'push' + - + name: Checkout + uses: actions/checkout@v3 + with: + fetch-depth: 0 + + - + name: Set up QEMU + uses: docker/setup-qemu-action@v2 + + - uses: docker/setup-buildx-action@v1 + name: Set up Docker Buildx + + - + name: Login to DockerHub + if: github.event_name != 'pull_request' + uses: docker/login-action@v2 + with: + registry: ${{ env.REGISTRY }} + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - + name: Docker meta + id: meta + uses: docker/metadata-action@v4 + with: + images: | + ${{ env.REGISTRY }}/${{ env.IMAGE }} + + + - + name: Build and push + uses: docker/build-push-action@v4 + with: + context: . + push: ${{ github.event_name != 'pull_request' }} + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + diff --git a/Dockerfile b/Dockerfile index dc594d9c..1285729c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,3 +8,8 @@ FROM gcr.io/distroless/static:nonroot WORKDIR / COPY --from=builder /app/sample/test-descriptor.yaml /app/server/quality-trace ./ CMD [ "/quality-trace" ] + + + + + diff --git a/application.yaml b/application.yaml new file mode 100644 index 00000000..42f5b999 --- /dev/null +++ b/application.yaml @@ -0,0 +1,28 @@ +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: test + finalizers: + - resources-finalizer.argocd.argoproj.io + namespace: argocd + +spec: + destination: + namespace: myapps + server: https://kubernetes.default.svc + project: default + source: + repoURL: https://github.com/Sheril5/quality-trace.git + path: charts/quality-trace + targetRevision: HEAD + helm: + valueFiles: + - values.yaml + syncPolicy: + syncOptions: + - CreateNamespace=true + automated: + selfHeal: true + prune: true + + diff --git a/charts/quality-trace/values.yaml b/charts/quality-trace/values.yaml index 68696f48..286588cf 100644 --- a/charts/quality-trace/values.yaml +++ b/charts/quality-trace/values.yaml @@ -5,7 +5,7 @@ replicaCount: 1 image: - repository: ghcr.io/kube-tarian/quality-trace/quality-trace + repository: ghcr.io/sheril5/quality-trace pullPolicy: Always # Overrides the image tag whose default is the chart appVersion. tag: "latest" @@ -83,6 +83,6 @@ tolerations: [] affinity: {} clickhouse: - url: http://localhost:9000 + url: http://chi-signoz-clickhouse-cluster-0-0.observability.svc.cluster.local:9000 username: admin password: admin diff --git a/test b/test new file mode 100644 index 00000000..57e110b7 --- /dev/null +++ b/test @@ -0,0 +1,58 @@ +ll +ll +ll +ll +lll +ll +ppp +kk +ppp +llll +lllllllllllll +kkkk +pp +pp +ll +p +pp +ll +ll +ppp +lll +pp +ll +ll +ll +ppp +ll +ll +kkk +lord +like +ll +kk +kk +k +god +jesus +hi +like +sun +sun +king +king +queen +google +mind +beet +gg +ll +sad +meet +like +look +lord +sweet +king +look +kite diff --git a/test-book.txt b/test-book.txt new file mode 100644 index 00000000..ce013625 --- /dev/null +++ b/test-book.txt @@ -0,0 +1 @@ +hello diff --git a/test1 b/test1 new file mode 100644 index 00000000..d89c41d9 --- /dev/null +++ b/test1 @@ -0,0 +1,68 @@ +hh +hello +ll +pp +pp +l +ll +kk +pp +pppp +ll +pppp +ooo +ll +kk +ll +kk +lll +ll +ii +hello-a +lll +hello-a +ll +ll +ll +h +ii +l +like +pp +god +g +ll +good +ll +l +jj +like +kkkk +five +u +https://github.com/Sheril5/quality-trace.git +u +kite +hello +jesus +jesus +hi +hello +ll +hii +look +lookup +web +net +kk +websecure +fio +sheril +lord +jj +sun +sky +tree +bike +son +sun diff --git a/test5 b/test5 new file mode 100644 index 00000000..048edb90 --- /dev/null +++ b/test5 @@ -0,0 +1,44 @@ +oo +hello +hi +pp +ll +ii +kk +pp +l +ll +p +p +ll +ll +ll +pp +ll +ll +ll +ll +ll +ll +ll +ll +ll +ll +kk +ll +ll +l +ll +ll +ll +ll +kk +kk +ll +ll +ll +kk +pp +ll +like +ll diff --git a/text-test b/text-test new file mode 100644 index 00000000..924b0677 --- /dev/null +++ b/text-test @@ -0,0 +1,16 @@ +hello +hi +one +yy +l +ll +ll +ll +pp +pp +oo +iii +ll +ll +ll +ll diff --git a/text2 b/text2 new file mode 100644 index 00000000..5cbefd82 --- /dev/null +++ b/text2 @@ -0,0 +1,36 @@ +hello +kk +hello-1 +h2 +ll +ii +bird +ll +sun +ll +ll +pp +leave +son +kk +holi +food +like +sun +tt +pp +five +like +star +five +one +star +root +tree +old +nope +this +quality +lok +cook +look