This is an automated email from the ASF dual-hosted git repository.

shuke987 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris-flink-connector.git


The following commit(s) were added to refs/heads/master by this push:
     new 37227e3d [Chore] Harden GitHub Actions and branch protection (#723)
37227e3d is described below

commit 37227e3da3de804573be015631b309b172466178
Author: Mingyu Chen (Rayner) <[email protected]>
AuthorDate: Thu Nov 26 16:37:21 2026 +0800

    [Chore] Harden GitHub Actions and branch protection (#723)
    
    * [Chore] Harden GitHub Actions and branch protection
    * Remove required review conversation resolution
---
 .asf.yaml                                   | 18 +++++++-
 .asf.yaml => .github/dependabot.yml         | 43 ++++++------------
 .github/workflows/approve-label-trigger.yml | 28 ------------
 .github/workflows/approve-label.yml         | 67 -----------------------------
 .github/workflows/build-connector.yml       | 21 ++++++---
 .github/workflows/checkstyle.yaml           | 15 ++++---
 .github/workflows/license-eyes.yml          | 12 ++++--
 .github/workflows/run-e2ecase-flink1.yml    | 12 ++++--
 .github/workflows/run-e2ecase-flink2.yml    |  7 ++-
 .github/workflows/run-itcase-flink1.yml     | 12 ++++--
 .github/workflows/run-itcase-flink2.yml     | 16 ++++---
 .licenserc.yaml                             |  2 +-
 12 files changed, 98 insertions(+), 155 deletions(-)

diff --git a/.asf.yaml b/.asf.yaml
index f8cf302c..dde343e9 100644
--- a/.asf.yaml
+++ b/.asf.yaml
@@ -31,11 +31,27 @@ github:
     squash:  true
     merge:   false
     rebase:  false
+  # Keep classic protection on master while ASF installs the ruleset.
   protected_branches:
     master:
       required_pull_request_reviews:
         dismiss_stale_reviews: true
-        required_approving_review_count: 0
+        required_approving_review_count: 1
+  rulesets:
+    - name: Default, release and compatibility branch protection
+      type: branch
+      branches:
+        includes:
+          - master
+          - "release-*"
+          - branch-for-flink-before-1.13
+          - branch-for-flinkcdc-2.x
+      restrict_deletion: true
+      restrict_force_push: true
+      required_pull_request_reviews:
+        dismiss_stale_reviews: true
+        required_approving_review_count: 1
+  dependabot_alerts: true
   features:
     issues: true
     projects: true
diff --git a/.asf.yaml b/.github/dependabot.yml
similarity index 55%
copy from .asf.yaml
copy to .github/dependabot.yml
index f8cf302c..2f109024 100644
--- a/.asf.yaml
+++ b/.github/dependabot.yml
@@ -15,32 +15,17 @@
 # limitations under the License.
 #
 
-github:
-  description: Flink Connector for Apache Doris
-  homepage: https://doris.apache.org/
-  labels:
-    - data-warehousing
-    - mpp
-    - olap
-    - dbms
-    - apache
-    - doris
-    - flink
-    - connector
-  enabled_merge_buttons:
-    squash:  true
-    merge:   false
-    rebase:  false
-  protected_branches:
-    master:
-      required_pull_request_reviews:
-        dismiss_stale_reviews: true
-        required_approving_review_count: 0
-  features:
-    issues: true
-    projects: true
-notifications:
-  issues:       [email protected]
-  commits:      [email protected]
-  pullrequests: [email protected]
- 
+version: 2
+updates:
+  - package-ecosystem: github-actions
+    directory: /
+    schedule:
+      interval: weekly
+    groups:
+      github-actions:
+        patterns:
+          - "*"
+      github-actions-security:
+        applies-to: security-updates
+        patterns:
+          - "*"
diff --git a/.github/workflows/approve-label-trigger.yml 
b/.github/workflows/approve-label-trigger.yml
deleted file mode 100644
index 1a9cb841..00000000
--- a/.github/workflows/approve-label-trigger.yml
+++ /dev/null
@@ -1,28 +0,0 @@
-# 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.
-#
----
-name: Label when reviewed
-on: pull_request_review
-jobs:
-
-  label-when-reviewed:
-    name: "Label PRs when reviewed"
-    runs-on: ubuntu-latest
-    steps:
-      - name: "Do nothing. Only trigger corresponding workflow_run event"
-        run: echo
diff --git a/.github/workflows/approve-label.yml 
b/.github/workflows/approve-label.yml
deleted file mode 100644
index f0225786..00000000
--- a/.github/workflows/approve-label.yml
+++ /dev/null
@@ -1,67 +0,0 @@
-# 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.
-#
----
-name: Label when approved workflow run
-on:
-  workflow_run:
-    workflows: ["Label when reviewed"]
-    types: ['requested']
-permissions:
-  # All other permissions are set to none
-  checks: write
-  contents: read
-  pull-requests: write
-
-jobs:
-
-  label-when-approved:
-    name: "Label when approved"
-    runs-on: ubuntu-latest
-    outputs:
-      isApprovedByCommiters: ${{ 
steps.label-when-approved-by-commiters.outputs.isApproved }}
-      isApprovedByAnyone: ${{ 
steps.label-when-approved-by-anyone.outputs.isApproved }}
-    steps:
-      - name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
-        uses: actions/checkout@v2
-        with:
-          persist-credentials: false
-          submodules: recursive
-      - name: "Get information about the original trigger of the run"
-        uses: ./.github/actions/get-workflow-origin
-        id: source-run-info
-        with:
-          token: ${{ secrets.GITHUB_TOKEN }}
-          sourceRunId: ${{ github.event.workflow_run.id }}
-      - name: Label when approved by commiters
-        uses: ./.github/actions/label-when-approved-action
-        id: label-when-approved-by-commiters
-        with:
-          token: ${{ secrets.GITHUB_TOKEN }}
-          label: 'approved'
-          require_committers_approval: 'true'
-          remove_label_when_approval_missing: 'true'
-          pullRequestNumber: ${{ 
steps.source-run-info.outputs.pullRequestNumber }}
-          comment: 'PR approved by at least one committer and no changes 
requested.'
-      - name: Label when approved by anyone
-        uses: ./.github/actions/label-when-approved-action
-        id: label-when-approved-by-anyone
-        with:
-          token: ${{ secrets.GITHUB_TOKEN }}
-          label: 'reviewed'
-          pullRequestNumber: ${{ 
steps.source-run-info.outputs.pullRequestNumber }}
-          comment: 'PR approved by anyone and no changes requested.'
diff --git a/.github/workflows/build-connector.yml 
b/.github/workflows/build-connector.yml
index b8e581e2..ebe06de4 100644
--- a/.github/workflows/build-connector.yml
+++ b/.github/workflows/build-connector.yml
@@ -33,12 +33,15 @@ jobs:
         shell: bash
     steps:
     - name: Checkout
-      uses: actions/checkout@master
+      uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+      with:
+        persist-credentials: false
 
     - name: Setup java
-      uses: actions/setup-java@v2
+      uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
       with:
-        distribution: adopt
+        problem-matcher: true
+        distribution: temurin
         java-version: '8'
 
     - name: Build flink connector 1.15
@@ -91,9 +94,10 @@ jobs:
           -Dflink.major.version=1.20
 
     - name: Setup java
-      uses: actions/setup-java@v2
+      uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
       with:
-        distribution: adopt
+        problem-matcher: true
+        distribution: temurin
         java-version: '17'
 
     - name: Build flink connector 2.0
@@ -138,11 +142,14 @@ jobs:
         working-directory: flink-doris-connector
     steps:
     - name: Checkout
-      uses: actions/checkout@v4
+      uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+      with:
+        persist-credentials: false
 
     - name: Setup Java 21
-      uses: actions/setup-java@v4
+      uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
       with:
+        problem-matcher: true
         distribution: temurin
         java-version: '21'
         cache: maven
diff --git a/.github/workflows/checkstyle.yaml 
b/.github/workflows/checkstyle.yaml
index 368d24e0..8158d2d4 100644
--- a/.github/workflows/checkstyle.yaml
+++ b/.github/workflows/checkstyle.yaml
@@ -21,21 +21,25 @@ name: Code Style Checker
 on:
   pull_request:
 
+permissions:
+  contents: read
+
 jobs:
   java-checkstyle:
     name: "CheckStyle"
     runs-on: ubuntu-latest
     steps:
       - name: Checkout
-        uses: actions/checkout@v3
+        uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # 
v7.0.1
         with:
           persist-credentials: false
           submodules: recursive
 
       - name: Setup java 8
-        uses: actions/setup-java@v2
+        uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
         with:
-          distribution: adopt
+          problem-matcher: true
+          distribution: temurin
           java-version: '8'
 
       - name: Run java checkstyle
@@ -43,9 +47,10 @@ jobs:
           cd flink-doris-connector && mvn clean install checkstyle:check 
-DskipTests -Pflink1 -pl flink-doris-connector-flink1 -am
 
       - name: Setup java 17
-        uses: actions/setup-java@v2
+        uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
         with:
-          distribution: adopt
+          problem-matcher: true
+          distribution: temurin
           java-version: '17'
 
       - name: Run java checkstyle
diff --git a/.github/workflows/license-eyes.yml 
b/.github/workflows/license-eyes.yml
index c9b4cd25..a3d4666a 100644
--- a/.github/workflows/license-eyes.yml
+++ b/.github/workflows/license-eyes.yml
@@ -22,14 +22,18 @@ on:
   push:
     branches:
       - master
+
+permissions:
+  contents: read
+
 jobs:
   license-check:
     name: "License Check"
     runs-on: ubuntu-latest
     steps:
       - name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
-        uses: actions/checkout@v2
+        uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # 
v7.0.1
+        with:
+          persist-credentials: false
       - name: Check License
-        uses: apache/[email protected]
-        env:
-          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+        uses: apache/skywalking-eyes@49d536241d6fe8f92400702b08710514dc298cd4 
# v0.2.0
diff --git a/.github/workflows/run-e2ecase-flink1.yml 
b/.github/workflows/run-e2ecase-flink1.yml
index c42e2521..369a32d0 100644
--- a/.github/workflows/run-e2ecase-flink1.yml
+++ b/.github/workflows/run-e2ecase-flink1.yml
@@ -21,6 +21,9 @@ on:
   pull_request:
   push:
 
+permissions:
+  contents: read
+
 jobs:
   build-extension:
     name: "Run E2ECases"
@@ -30,12 +33,15 @@ jobs:
         shell: bash
     steps:
     - name: Checkout
-      uses: actions/checkout@master
+      uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+      with:
+        persist-credentials: false
 
     - name: Setup java
-      uses: actions/setup-java@v2
+      uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
       with:
-        distribution: adopt
+        problem-matcher: true
+        distribution: temurin
         java-version: '8'
 
     - name: Configure Doris prerequisites
diff --git a/.github/workflows/run-e2ecase-flink2.yml 
b/.github/workflows/run-e2ecase-flink2.yml
index 1cace678..b47f9100 100644
--- a/.github/workflows/run-e2ecase-flink2.yml
+++ b/.github/workflows/run-e2ecase-flink2.yml
@@ -38,11 +38,14 @@ jobs:
         shell: bash
     steps:
     - name: Checkout
-      uses: actions/checkout@v4
+      uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+      with:
+        persist-credentials: false
 
     - name: Setup Java ${{ matrix.java }}
-      uses: actions/setup-java@v4
+      uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
       with:
+        problem-matcher: true
         distribution: temurin
         java-version: ${{ matrix.java }}
         cache: maven
diff --git a/.github/workflows/run-itcase-flink1.yml 
b/.github/workflows/run-itcase-flink1.yml
index bec07504..6c24c960 100644
--- a/.github/workflows/run-itcase-flink1.yml
+++ b/.github/workflows/run-itcase-flink1.yml
@@ -21,6 +21,9 @@ on:
   pull_request:
   push:
 
+permissions:
+  contents: read
+
 jobs:
   build-extension:
     name: "Run ITCases"
@@ -30,12 +33,15 @@ jobs:
         shell: bash
     steps:
     - name: Checkout
-      uses: actions/checkout@master
+      uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+      with:
+        persist-credentials: false
 
     - name: Setup java
-      uses: actions/setup-java@v2
+      uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
       with:
-        distribution: adopt
+        problem-matcher: true
+        distribution: temurin
         java-version: '8'
 
     - name: Configure Doris prerequisites
diff --git a/.github/workflows/run-itcase-flink2.yml 
b/.github/workflows/run-itcase-flink2.yml
index 116989bf..31342df3 100644
--- a/.github/workflows/run-itcase-flink2.yml
+++ b/.github/workflows/run-itcase-flink2.yml
@@ -33,12 +33,15 @@ jobs:
         shell: bash
     steps:
     - name: Checkout
-      uses: actions/checkout@master
+      uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+      with:
+        persist-credentials: false
 
     - name: Setup java
-      uses: actions/setup-java@v2
+      uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
       with:
-        distribution: adopt
+        problem-matcher: true
+        distribution: temurin
         java-version: '17'
 
     - name: Configure Doris prerequisites
@@ -81,11 +84,14 @@ jobs:
         shell: bash
     steps:
     - name: Checkout
-      uses: actions/checkout@v4
+      uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+      with:
+        persist-credentials: false
 
     - name: Setup Java 21
-      uses: actions/setup-java@v4
+      uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # 
v6.3.0
       with:
+        problem-matcher: true
         distribution: temurin
         java-version: '21'
         cache: maven
diff --git a/.licenserc.yaml b/.licenserc.yaml
index 691b2090..ddb6b4bb 100644
--- a/.licenserc.yaml
+++ b/.licenserc.yaml
@@ -15,4 +15,4 @@ header:
     - 
'flink-doris-connector/flink-doris-connector-base/src/test/resources/container/'
     - 
'flink-doris-connector/flink-doris-connector-base/src/test/resources/tls/'
 
-  comment: on-failure
+  comment: never


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to