diff --git a/.github/workflows/build-windows.yml b/.github/workflows/build-windows.yml new file mode 100644 index 0000000000000..a9e06ccfd6d9d --- /dev/null +++ b/.github/workflows/build-windows.yml @@ -0,0 +1,69 @@ +name: Build gRPC for Windows + +on: + push: + branches: ['nh-57056-cpp17'] + + # Inputs for reusable workflow + + workflow_call: + inputs: + logLevel: + description: 'Log level' + required: true + default: 'warning' + type: string + + # Inputs for manually triggered workflow + + workflow_dispatch: + inputs: + logLevel: + description: 'Log level' + required: true + default: 'warning' + +jobs: + build: + strategy: + matrix: + arch: ['32', '64'] + configuration: ['Release', 'Debug'] + fail-fast: false + + runs-on: windows-2022 + + steps: + - name: Set git to use LF + run: | + git config --global core.autocrlf false + git config --global core.eol lf + + - name: Checkout ${{ github.ref }} + uses: actions/checkout@v3 + + - name: Checkout gRPC repository + uses: actions/checkout@v3 + with: + path: grpc + + - name: Add msbuild to PATH + uses: microsoft/setup-msbuild@v1.0.2 + + - name: Configure AWS credentials + uses: aws-actions/configure-aws-credentials@v1-node16 + with: + aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} + aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + aws-region: ${{ secrets.AWS_REGION }} + + - name: Build gRPC ${{ matrix.arch }} ( ${{ matrix.configuration }} ) + shell: cmd + run: | + ${{ github.workspace }}/grpc/build_windows.bat ${{ matrix.configuration }} ${{ matrix.arch }} + working-directory: ${{ github.workspace }} + env: + WORKSPACE: ${{ github.workspace }} + MSBUILD_COMMAND: msbuild.exe + +