12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273 |
- name: Ya-Build-and-Test
- on:
- workflow_call:
- inputs:
- build_target:
- type: string
- default: "ydb/"
- description: "limit build and test to specific target"
- sanitizer:
- type: string
- default: "none"
- description: "sanitizer type"
- runner_kind:
- type: string
- required: true
- description: "self-hosted or provisioned"
- runner_label:
- type: string
- default: "linux"
- description: "runner label"
- run_build:
- type: boolean
- default: true
- description: "run build"
- run_tests:
- type: boolean
- default: true
- description: "run tests"
- log_suffix:
- type: string
- required: true
- description: "suffix for current build. uses as testmo source and s3 subfolder"
- jobs:
- main:
- name: Build and test
- runs-on: [ self-hosted, "${{ inputs.runner_kind }}", "${{ inputs.runner_label }}" ]
- steps:
- - name: Checkout
- uses: actions/checkout@v3
- - name: Prepare s3cmd
- uses: ./.github/actions/s3cmd
- with:
- s3_bucket: ${{ vars.AWS_BUCKET }}
- s3_endpoint: ${{ vars.AWS_ENDPOINT }}
- s3_key_id: ${{ secrets.AWS_KEY_ID }}
- s3_key_secret: ${{ secrets.AWS_KEY_VALUE }}
- log_suffix: ${{ inputs.log_suffix }}
- - name: Build
- uses: ./.github/actions/build_ya
- if: inputs.run_build
- with:
- build_target: ${{ inputs.build_target }}
- sanitizer: ${{ inputs.sanitizer }}
- bazel_remote_uri: ${{ vars.REMOTE_CACHE_URL_YA || '' }}
- bazel_remote_username: ${{ secrets.REMOTE_CACHE_USERNAME }}
- bazel_remote_password: ${{ secrets.REMOTE_CACHE_PASSWORD }}
- - name: Run tests
- uses: ./.github/actions/test_ya
- if: inputs.run_tests
- with:
- build_target: ${{ inputs.build_target }}
- sanitizer: ${{ inputs.sanitizer }}
- log_suffix: ${{ inputs.log_suffix }}
- testman_token: ${{ secrets.TESTMO_TOKEN }}
- testman_url: ${{ vars.TESTMO_URL }}
- testman_project_id: ${{ vars.TESTMO_PROJECT_ID }}
- bazel_remote_uri: ${{ vars.REMOTE_CACHE_URL_YA || '' }}
|