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

ppkarwasz pushed a commit to branch atr
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git

commit 33a2acf422d9f414d3ab49064ca1e3403bbfd090
Author: Piotr P. Karwasz <[email protected]>
AuthorDate: Wed Jun 3 08:48:19 2026 +0200

    Add `deploy-atr` workflow
    
    Add a workflow that, on push to a `release-atr/*` branch:
    
    - checks out the repository,
    - verifies that the branch and project version match,
    - builds `tar.gz` and `zip` source
    distributions via `git archive`, and
     - uploads them to ATR using `apache/tooling-actions/deploy-atr`.
    
    This is an experimental workflow targeting the ATR test instance.
---
 .github/workflows/deploy-atr.yaml | 65 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 65 insertions(+)

diff --git a/.github/workflows/deploy-atr.yaml 
b/.github/workflows/deploy-atr.yaml
new file mode 100644
index 0000000000..b27712b4c7
--- /dev/null
+++ b/.github/workflows/deploy-atr.yaml
@@ -0,0 +1,65 @@
+#
+# 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: deploy-atr
+
+on:
+  push:
+    branches:
+      - "release-atr/*"
+
+permissions: { }
+
+jobs:
+
+  deploy-atr:
+    if: github.repository == 'apache/logging-log4j2'
+    runs-on: ubuntu-latest
+    permissions:
+      id-token: write    # Required for OIDC authentication against ATR
+      contents: read
+    steps:
+
+      - name: Checkout repository
+        uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683    # 
v4.2.2
+
+      - name: Extract version
+        id: version
+        run: echo "version=${GITHUB_REF_NAME#release-atr/}" >> "$GITHUB_OUTPUT"
+
+      - name: Verify version
+        run: |
+          version='${{ steps.version.outputs.version }}'
+          if ! grep -qF "<revision>${version}</revision>" pom.xml; then
+            echo "::error::Mismatch between branch name and project version"
+            exit 1
+          fi
+
+      - name: Create source distributions
+        run: |
+          version='${{ steps.version.outputs.version }}'
+          prefix="apache-log4j-${version}-src/"
+          mkdir -p dist
+          git archive --format=tar.gz --prefix="${prefix}" -o 
"dist/apache-log4j-${version}-src.tar.gz" HEAD
+          git archive --format=zip --prefix="${prefix}" -o 
"dist/apache-log4j-${version}-src.zip" HEAD
+
+      - name: Upload to ATR
+        uses: 
apache/tooling-actions/upload-to-atr@5bd24e53798bc79aa7bb69f62154a6b1e18ffd6e
+        with:
+          project: log4j
+          version: ${{ steps.version.outputs.version }}
+          src: dist

Reply via email to