mirror of
https://github.com/spring-projects/spring-boot.git
synced 2024-08-29 03:06:45 +08:00
054a1a0c0f
See gh-40980
51 lines
1.9 KiB
YAML
51 lines
1.9 KiB
YAML
name: Sync to Maven Central
|
|
description: Syncs a release to Maven Central and waits for it to be available for use
|
|
inputs:
|
|
jfrog-cli-config-token:
|
|
description: 'Config token for the JFrog CLI'
|
|
required: true
|
|
spring-boot-version:
|
|
description: 'The version of Spring Boot that is being synced to Central'
|
|
required: true
|
|
ossrh-s01-token-username:
|
|
description: 'Username for authentication with s01.oss.sonatype.org'
|
|
required: true
|
|
ossrh-s01-token-password:
|
|
description: 'Password for authentication with s01.oss.sonatype.org'
|
|
required: true
|
|
ossrh-s01-staging-profile:
|
|
description: 'Staging profile to use when syncing to Central'
|
|
required: true
|
|
runs:
|
|
using: composite
|
|
steps:
|
|
- name: Set Up JFrog CLI
|
|
uses: jfrog/setup-jfrog-cli@7c95feb32008765e1b4e626b078dfd897c4340ad # v4.1.2
|
|
env:
|
|
JF_ENV_SPRING: ${{ inputs.jfrog-cli-config-token }}
|
|
- name: Download Release Artifacts
|
|
shell: bash
|
|
run: jf rt download --spec ${{ format('{0}/artifacts.spec', github.action_path) }} --spec-vars 'buildName=${{ format('spring-boot-{0}', inputs.spring-boot-version) }};buildNumber=${{ github.run_number }}'
|
|
- name: Sync
|
|
uses: spring-io/nexus-sync-action@42477a2230a2f694f9eaa4643fa9e76b99b7ab84 # v0.0.1
|
|
with:
|
|
username: ${{ inputs.ossrh-s01-token-username }}
|
|
password: ${{ inputs.ossrh-s01-token-password }}
|
|
staging-profile-name: ${{ inputs.ossrh-s01-staging-profile }}
|
|
create: true
|
|
upload: true
|
|
close: true
|
|
release: true
|
|
generate-checksums: true
|
|
- name: Await
|
|
shell: bash
|
|
run: |
|
|
url=${{ format('https://repo.maven.apache.org/maven2/org/springframework/boot/spring-boot/{0}/spring-boot-{0}.jar', inputs.spring-boot-version) }}
|
|
echo "Waiting for $url"
|
|
until curl --fail --head --silent $url > /dev/null
|
|
do
|
|
echo "."
|
|
sleep 60
|
|
done
|
|
echo "$url is available"
|