diff --git a/.github/build-push-env-docker.yml b/.github/workflows/build-push-env-docker.yml similarity index 100% rename from .github/build-push-env-docker.yml rename to .github/workflows/build-push-env-docker.yml diff --git a/.github/workflows/ci-pull-request-always-pass.yaml b/.github/workflows/ci-pull-request-always-pass.yaml new file mode 100644 index 0000000000..6559541a4d --- /dev/null +++ b/.github/workflows/ci-pull-request-always-pass.yaml @@ -0,0 +1,54 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +--- +# There are 'paths' filters for ci-pull-request.yaml, +# it can be skipped, but lead CI pending, we add this +# 'always pass' action to resolve it, see more details: +# https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/troubleshooting-required-status-checks#handling-skipped-but-required-checks + +name: Code Lint and Unit Test + +on: + # run on each pull request + pull_request: + types: [ synchronize, opened, reopened ] + paths-ignore: + - src + - rdsn + - run.sh + branches: + - master + - 'v[0-9]+.*' # release branch + - ci-test # testing branch for github action + - '*dev' + + # for manually triggering workflow + workflow_dispatch: + +jobs: + lint: + name: Lint + runs-on: ubuntu-latest + steps: + - run: 'echo "No build required" ' + + test: + name: Test + needs: lint + runs-on: ubuntu-latest + steps: + - run: 'echo "No build required" ' diff --git a/.github/workflows/ci-pull-request.yaml b/.github/workflows/ci-pull-request.yaml index 4a21c6b572..b40e3ceee3 100644 --- a/.github/workflows/ci-pull-request.yaml +++ b/.github/workflows/ci-pull-request.yaml @@ -21,17 +21,22 @@ # it's recommended to create a PR against the ci-test branch to test if it works # as expected. -name: pull_request +name: Code Lint and Unit Test on: # run on each pull request pull_request: types: [ synchronize, opened, reopened ] + paths: + - src + - rdsn + - run.sh branches: - master - 'v[0-9]+.*' # release branch - ci-test # testing branch for github action - '*dev' + # for manually triggering workflow workflow_dispatch: diff --git a/.circleci/config.yml b/.github/workflows/dockerfile_linter.yml similarity index 55% rename from .circleci/config.yml rename to .github/workflows/dockerfile_linter.yml index 6866e73f33..b6ba679019 100644 --- a/.circleci/config.yml +++ b/.github/workflows/dockerfile_linter.yml @@ -15,12 +15,28 @@ # specific language governing permissions and limitations # under the License. --- -version: 2.1 -orbs: - docker: circleci/docker@2.0.3 -workflows: - lint: - jobs: - - docker/hadolint: - dockerfiles: 'docker/bcc-centos7/Dockerfile:docker/ci-env/Dockerfile:docker/clang-format-3.9/Dockerfile:docker/pegasus-build-env/centos7/Dockerfile:docker/pegasus-build-env/ubuntu1604/Dockerfile:docker/pegasus-build-env/ubuntu1804/Dockerfile:docker/pegasus-build-env/ubuntu2004/Dockerfile:docker/pegasus-docker-compose/image_for_prebuilt_bin/Dockerfile:docker/thirdparties-bin/Dockerfile:docker/thirdparties-src/Dockerfile' - ignore-rules: 'DL3033,DL3013,DL3059,SC2086,DL3003,SC2164,DL3008,DL3007,DL3006' +name: Lint Dockerfile + +on: + # run on each pull request + pull_request: + types: [ synchronize, opened, reopened ] + branches: + - master + - 'v[0-9]+.*' # release branch + - ci-test # testing branch for github action + - '*dev' + + # for manually triggering workflow + workflow_dispatch: + +jobs: + linter: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Lint Dockerfile + uses: hadolint/hadolint-action@v2.1.0 + with: + recursive: true + ignore: 'DL3033,DL3013,DL3059,SC2086,DL3003,SC2164,DL3008,DL3007,DL3006' diff --git a/.github/pegasus-regular-build.yml b/.github/workflows/pegasus-regular-build.yml similarity index 100% rename from .github/pegasus-regular-build.yml rename to .github/workflows/pegasus-regular-build.yml diff --git a/.github/thirdparty-regular-push.yml b/.github/workflows/thirdparty-regular-push.yml similarity index 100% rename from .github/thirdparty-regular-push.yml rename to .github/workflows/thirdparty-regular-push.yml diff --git a/docker/README.md b/docker/README.md index cddd40932b..e9f5f52643 100644 --- a/docker/README.md +++ b/docker/README.md @@ -23,11 +23,11 @@ to deploying a standalone cluster of Pegasus containers on your local machine. ## Workflows -![Build and publish multi pegasus-build-env docker images](https://github.com/pegasus-kv/pegasus-docker/workflows/BuildCompilationEnvDocker-build%20and%20publish%20multi%20compilation%20os%20env/badge.svg?branch=master) +![Build and publish multi pegasus-build-env docker images](https://github.com/apache/incubator-pegasus/workflows/BuildCompilationEnvDocker-build%20and%20publish%20multi%20compilation%20os%20env/badge.svg?branch=master) -![Build and publish multi os env thirdparty docker images every week](https://github.com/pegasus-kv/pegasus-docker/workflows/BuildThirdpartyDockerRegularly-build%20and%20publish%20thirdparty%20every%20week/badge.svg?branch=master) +![Build and publish multi os env thirdparty docker images every week](https://github.com/apache/incubator-pegasus/workflows/BuildThirdpartyDockerRegularly-build%20and%20publish%20thirdparty%20every%20week/badge.svg?branch=master) -![Build pegasus/rdsn regularly based env and thirdparty docker everyday](https://github.com/pegasus-kv/pegasus-docker/workflows/BuildPegasusRegularly-build%20pegasus%20and%20rdsn%20on%20different%20env%20every%20day/badge.svg?branch=master) +![Build pegasus/rdsn regularly based env and thirdparty docker everyday](https://github.com/apache/incubator-pegasus/workflows/BuildPegasusRegularly-build%20pegasus%20and%20rdsn%20on%20different%20env%20every%20day/badge.svg?branch=master) ## pegasus-build-env