Skip to content

build: experimenting -- do not merge #10

build: experimenting -- do not merge

build: experimenting -- do not merge #10

name: Secrets Testing
on:
push:
branches: [main,build-secrets-testing]
pull_request:
workflow_dispatch:
permissions:
contents: read
packages: write
jobs:
secrets-testing:
name: Secrets Testing
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Construct Maven settings file
run: |
cat > /tmp/maven_settings.xml <<'EOF'
<?xml version="1.0" encoding="UTF-8"?>
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
http://maven.apache.org/xsd/settings-1.0.0.xsd">
<servers>
<server>
<id>central</id>
<username>${{ secrets.MAVEN_USERNAME }}</username>
<password>${{ secrets.MAVEN_PASSWORD }}</password>
</server>
</servers>
</settings>
EOF
- name: Publish Java package with Docker
uses: docker/build-push-action@v6
with:
context: .
target: openfeature-provider-java.install
cache-from: type=registry,ref=ghcr.io/${{ github.repository }}/cache:main
secrets: |
maven_settings=/tmp/maven_settings.xml
gpg_private_key=${{ secrets.GPG_PRIVATE_KEY }}
gpg_pass=${{ secrets.SIGN_KEY_PASS }}