Skip to content

Commit

Permalink
added the port to fix the Makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
shubhadapaithankar committed Aug 22, 2024
1 parent a850256 commit d42efd2
Show file tree
Hide file tree
Showing 2 changed files with 100 additions and 22 deletions.
120 changes: 99 additions & 21 deletions .pipelines/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,60 +20,138 @@ pr:
exclude:
- docs/*

variables:
- template: vars.yml

resources:
containers:
- container: golang
image: registry.access.redhat.com/ubi8/go-toolset:1.21.11-1.1720406008
options: --user=0
- container: python
image: registry.access.redhat.com/ubi8/python-39:latest
options: --user=0

variables:
- template: vars.yml

stages:
- stage: NEW_HOTNESS
- stage: NotContainerized
jobs:
- job: Build_Lint_Test_RP_And_Portal
- job: Python_Unit_Tests
pool:
name: 1es-aro-ci-pool
variables:
HOME: $(Agent.BuildDirectory)

steps:
- template: ./templates/template-checkout.yml
- script: |
set -xe
export NO_CACHE=true
make ci-rp
make test-python
[[ -z "$(git status -s)" ]]
displayName: 🧪Run Python Unit Tests
target: python
- job: Build_and_Test_Az_ARO_Extension
- job: Golang_Unit_Tests
pool:
name: 1es-aro-ci-pool
variables:
GOCACHE: /tmp/gocache
steps:
- template: ./templates/template-checkout.yml

- script: |
set -xe
go version
go env
displayName: Print Go version & env
target: golang
- script: |
set -xe
make generate
[[ -z "$(git status -s)" ]]
displayName: ⚙️ Run Golang code generate
target: golang
- script: |
set -xe
make build-all
[[ -z "$(git status -s)" ]]
displayName: 🕵️ Build Golang code
target: golang
- script: |
set -xe
make unit-test-go
displayName: 🧪 Run Golang unit tests
target: golang
- task: PublishTestResults@2
displayName: 📊 Publish tests results
inputs:
testResultsFiles: $(System.DefaultWorkingDirectory)/**/report.xml
condition: succeededOrFailed()

- script: |
set -xe
go run github.com/axw/gocov/[email protected] convert cover.out | go run github.com/AlekSi/[email protected] > coverage.xml
displayName: ⚙️ Process Reports
condition: succeededOrFailed()
target: golang
- task: PublishCodeCoverageResults@1
displayName: 📈 Publish code coverage
inputs:
codeCoverageTool: Cobertura
summaryFileLocation: $(System.DefaultWorkingDirectory)/**/coverage.xml
failIfCoverageEmpty: false
condition: succeededOrFailed()
target: golang

- job: Lint_Admin_Portal
pool:
name: 1es-aro-ci-pool
steps:
- template: ./templates/template-checkout.yml
- script: |
set -xe
make lint-admin-portal
displayName: 🧹 Lint Admin Portal
- stage: Containerized
dependsOn: []
jobs:
- job: Build_Lint_Test_RP_And_Portal
pool:
name: 1es-aro-ci-pool
steps:
- template: ./templates/template-checkout.yml
- script: |
set -xe
export NO_CACHE=true
make azext-aro
. ./hack/e2e/run-rp-and-e2e.sh
run_podman
validate_podman_running
export PODMAN_REMOTE_ARGS="-r --url=tcp://localhost:8888"
make ci-rp
- job: Lint_Az_ARO_Extension
- job: Build_and_Test_Az_ARO_Extension
pool:
name: 1es-aro-ci-pool
steps:
- template: ./templates/template-checkout.yml
- script: |
set -xe
make test-python
export NO_CACHE=true
. ./hack/e2e/run-rp-and-e2e.sh
run_podman
validate_podman_running
export PODMAN_REMOTE_ARGS="-r --url=tcp://localhost:8888"
make azext-aro
- stage: Golang_Code_Generation
jobs:
- job: Run_Golang_Code_Generate
displayName: "⚙️ Run Golang code generate"
- job: Lint_Az_ARO_Extension
pool:
name: 1es-aro-ci-pool
container: golang
variables:
GOCACHE: /tmp/gocache # Set the Go build cache to a writable directory
steps:
- template: ./templates/template-checkout.yml
- script: |
set -xe
make generate
[[ -z "$(git status -s)" ]]
displayName: "Run Golang Code Generate"
make test-python

Check failure on line 157 in .pipelines/ci.yml

View workflow job for this annotation

GitHub Actions / mega-linter-yaml

157:29 [new-line-at-end-of-file] no new line character at the end of file
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ E2E_FLAGS ?= -test.v --ginkgo.v --ginkgo.timeout 180m --ginkgo.flake-attempts=2
E2E_LABEL ?= !smoke
GO_FLAGS ?= -tags=containers_image_openpgp,exclude_graphdriver_btrfs,exclude_graphdriver_devicemapper
NO_CACHE ?= true
PODMAN_REMOTE_ARGS ?=
PODMAN_REMOTE_ARGS ?=

export GOFLAGS=$(GO_FLAGS)

Expand Down

0 comments on commit d42efd2

Please sign in to comment.