# Copyright (c) 2020-2023 Project CHIP Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

name: Cirque

on:
    push:
        branches:
            - master
            - 'v*-branch'
    pull_request:
    merge_group:
    workflow_dispatch:

concurrency:
    group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }}
    cancel-in-progress: true

env:
    CHIP_NO_LOG_TIMESTAMPS: true
    
jobs:
    cirque:
        name: Cirque

        env:
            GITHUB_CACHE_PATH: /tmp/cirque-cache

        runs-on: ubuntu-latest
        if: github.actor != 'restyled-io[bot]'

        # need to run with privilege, which isn't supported by job.XXX.contaner
        #  https://github.com/actions/container-action/issues/2
        #         container:
        #             image: ghcr.io/project-chip/chip-build-cirque:<VERSION_HERE>
        #             volumes:
        #                 - "/tmp:/tmp"
        #                 - "/dev/pts:/dev/pts"
        #             env:
        #                 LOG_DIR: /tmp/cirque_test_output/
        #                 CLEANUP_DOCKER_FOR_CI: 1
        #             options: "--privileged"

        steps:
            - name: Checkout
              uses: actions/checkout@v4
            - name: Checkout submodules
              uses: ./.github/actions/checkout-submodules
              with:
                platform: linux

            # TODO: Is what's being cached here actually compatible with a regular bootstrap?
            - name: Bootstrap Cache
              uses: ./.github/actions/bootstrap-cache
            - name: Bootstrap Cirque
              run: |
                  integrations/docker/images/stage-2/chip-build-cirque/run.sh \
                    -- sh -c " \
                       git config --global --add safe.directory '*' \
                       && bash scripts/bootstrap.sh \
                       && chown -R $(id -u):$(id -g) .environment \
                    "

            - name: Get Cirque Bootstrap cache key
              id: cirque-bootstrap-cache-key
              run: echo "val=$(scripts/tests/cirque_tests.sh cachekeyhash)" >> $GITHUB_OUTPUT
            - uses: Wandalen/wretry.action@v1.4.10
              name: Cirque Bootstrap cache
              if: ${{ !env.ACT }}
              continue-on-error: true
              timeout-minutes: 10
              with:
                action: buildjet/cache@v3
                attempt_limit: 3
                attempt_delay: 2000
                with: |
                  key: ${{ runner.os }}-cirque-${{ steps.cirque-bootstrap-cache-key.outputs.val }}
                  restore-keys: ${{ runner.os }}-cirque-
                  path: ${{ env.GITHUB_CACHE_PATH }}
            - name: Cirque Bootstrap
              run: |
                  integrations/docker/images/stage-2/chip-build-cirque/run.sh \
                    --env GITHUB_ACTION_RUN=1 \
                    --env GITHUB_CACHE_PATH=${{ env.GITHUB_CACHE_PATH }} \
                    --volume /tmp:/tmp \
                    -- sh -c " \
                       git config --global --add safe.directory '*' \
                       && scripts/tests/cirque_tests.sh bootstrap \
                      "

            - name: Artifact suffix
              id: outsuffix
              uses: haya14busa/action-cond@v1
              if: ${{ !env.ACT }}
              with:
                  cond: ${{ github.event.pull_request.number == '' }}
                  if_true: "${{ github.sha }}"
                  if_false: "pull-${{ github.event.pull_request.number }}"
            - name: Build Binaries
              run: |
                  integrations/docker/images/stage-2/chip-build-cirque/run.sh \
                    -- sh -c " \
                       git config --global --add safe.directory '*' \
                       && scripts/build/gn_gen_cirque.sh \
                      "
            - name: Run Tests
              run: |
                  integrations/docker/images/stage-2/chip-build-cirque/run.sh \
                     --env LOG_DIR=/tmp/cirque_test_output \
                     --env CLEANUP_DOCKER_FOR_CI=1 \
                     --env GITHUB_ACTION_RUN=1 \
                     --privileged \
                     --volume /tmp:/tmp \
                     --volume /dev/pts:/dev/pts \
                     -- sh -c " \
                       git config --global --add safe.directory '*' \
                       && scripts/tests/cirque_tests.sh run_all_tests \
                      "
                   

            - name: Uploading Binaries
              uses: actions/upload-artifact@v4
              if: ${{ always() && !env.ACT }}
              with:
                  name: cirque_log-${{steps.outsuffix.outputs.value}}-logs
                  path: /tmp/cirque_test_output/
