diff options
Diffstat (limited to '.github/workflows/ci-build.yml')
-rwxr-xr-x | .github/workflows/ci-build.yml | 119 |
1 files changed, 0 insertions, 119 deletions
diff --git a/.github/workflows/ci-build.yml b/.github/workflows/ci-build.yml deleted file mode 100755 index 8ec3eec9..00000000 --- a/.github/workflows/ci-build.yml +++ /dev/null @@ -1,119 +0,0 @@ -name: CI - -on: [ push, pull_request ] - -jobs: - build: - name: Build (PHP ${{ matrix.php }}, Go ${{ matrix.go }}, OS ${{ matrix.os }}) - runs-on: ${{ matrix.os }} - strategy: - fail-fast: false - matrix: - php: [ 7.4, 8.0 ] - go: [ 1.14, 1.15 ] - os: [ ubuntu-20.04 ] - env: - GO111MODULE: on - steps: - - name: Set up Go ${{ matrix.go }} - uses: actions/setup-go@v1 - with: - go-version: ${{ matrix.go }} - - - name: Set up PHP ${{ matrix.php }} - uses: shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php }} - extensions: dom - coverage: xdebug - - - name: Check out code - uses: actions/checkout@v2 - with: - fetch-depth: 1 - - - name: Show versions - run: php -v ; composer -V ; go version - - - name: Debug if needed - env: - DEBUG: ${{ secrets.DEBUG }} - run: if [[ "$DEBUG" == "true" ]]; then env && go env; fi - - - name: Syntax check only (lint) - run: find ./src/ -name "*.php" -print0 | xargs -0 -n1 -P8 php -l - - - name: Get Composer Cache Directory # Docs: <https://github.com/actions/cache/blob/master/examples.md#php---composer> - id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" - - - name: Cache dependencies # Docs: <https://github.com/actions/cache/blob/master/examples.md#php---composer> - uses: actions/cache@v1 - with: - path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} - restore-keys: ${{ runner.os }}-composer- - - - name: Install Composer dependencies - run: composer install --prefer-dist --no-interaction - - # - name: Analyze PHP sources - # run: composer analyze - - - name: Install Go dependencies - run: go mod download - - - name: Run golang tests - run: | - mkdir ./coverage-ci - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/lib.txt -covermode=atomic . - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/rpc_config.txt -covermode=atomic ./plugins/rpc - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/rpc.txt -covermode=atomic ./plugins/rpc/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/plugin_config.txt -covermode=atomic ./plugins/config/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/logger.txt -covermode=atomic ./plugins/logger/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/server.txt -covermode=atomic ./plugins/server/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/metrics.txt -covermode=atomic ./plugins/metrics/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/informer.txt -covermode=atomic ./plugins/informer/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/informer.txt -covermode=atomic ./plugins/resetter/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/attributes.txt -covermode=atomic ./plugins/http/attributes - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/http_tests.txt -covermode=atomic ./plugins/http/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/gzip.txt -covermode=atomic ./plugins/gzip/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/static.txt -covermode=atomic ./plugins/static/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/static_root.txt -covermode=atomic ./plugins/static - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/headers.txt -covermode=atomic ./plugins/headers/tests - go test -v -race -cover -tags=debug -coverprofile=./coverage-ci/checker.txt -covermode=atomic ./plugins/checker/tests - cat ./coverage-ci/*.txt > ./coverage-ci/summary.txt - - - name: Run code coverage - uses: codecov/codecov-action@v1 - with: - token: ${{ secrets.CODECOV_TOKEN }} - files: summary.txt - flags: unittests - name: codecov-umbrella - fail_ci_if_error: false - verbose: true - - - golangci-check: - name: runner / golangci-lint - runs-on: ubuntu-latest - steps: - - name: Check out code into the Go module directory - uses: actions/checkout@v1 - - name: golangci-lint - uses: reviewdog/action-golangci-lint@v1 - with: - github_token: ${{ secrets.github_token }} - -# image: -# name: Build docker image -# runs-on: ubuntu-latest -# steps: -# - name: Check out code -# uses: actions/checkout@v2 -# with: -# fetch-depth: 1 -# -# - name: Build image -# run: docker build -t rr:local -f Dockerfile . |