@@ -25,25 +25,6 @@ concurrency:
25
25
cancel-in-progress : true
26
26
27
27
jobs :
28
- check-if-aar-exists :
29
- name : check-if-aar-exists
30
- runs-on : ubuntu-22.04
31
- timeout-minutes : 10
32
- steps :
33
- - name : Check if this RC version is already in S3
34
- shell : bash
35
- run : |
36
- VERSION="${{ inputs.version }}"
37
- if [ -z "$VERSION" ]; then
38
- echo "No version name specified. Will create a snapshot AAR"
39
- exit 0
40
- fi
41
- if curl -I "https://ossci-android.s3.amazonaws.com/executorch/release/${VERSION}/executorch.aar" | grep "200 OK"; then
42
- echo "AAR already exists at https://ossci-android.s3.amazonaws.com/executorch/release/${VERSION}/executorch.aar"
43
- echo "Will skip build/upload"
44
- exit 1
45
- fi
46
-
47
28
build-aar :
48
29
name : build-aar
49
30
needs : check-if-aar-exists
@@ -121,32 +102,3 @@ jobs:
121
102
if [[ "$UPLOAD_TO_MAVEN" == "true" ]]; then
122
103
(cd extension/android; ANDROID_HOME="${ANDROID_SDK:-/opt/android/sdk}" ./gradlew ${GRADLE_ARGS} :executorch_android:publishToMavenCentral)
123
104
fi
124
-
125
- upload-release-aar :
126
- name : upload-release-aar
127
- needs : build-aar
128
- runs-on : ubuntu-22.04
129
- timeout-minutes : 10
130
- permissions :
131
- id-token : write
132
- contents : read
133
- steps :
134
- - name : configure aws credentials
135
- uses :
aws-actions/[email protected]
136
- with :
137
- role-to-assume : arn:aws:iam::308535385114:role/gha_executorch_upload-frameworks-android
138
- aws-region : us-east-1
139
- - name : Upload AAR RC to AWS S3
140
- shell : bash
141
- run : |
142
- wget https://gha-artifacts.s3.amazonaws.com/${{ github.repository }}/${{ github.run_id }}/artifacts/executorch.aar
143
- shasum -a 256 executorch.aar > executorch.aar.sha256sums
144
-
145
- pip install awscli==1.32.18
146
- AWS_CMD="aws s3 cp"
147
- VERSION="${{ inputs.version }}"
148
- if [ -z "$VERSION" ]; then
149
- VERSION="snapshot-$(date +"%Y%m%d")"
150
- fi
151
- ${AWS_CMD} executorch.aar s3://ossci-android/executorch/release/${VERSION}/executorch.aar --acl public-read
152
- ${AWS_CMD} executorch.aar.sha256sums s3://ossci-android/executorch/release/${VERSION}/executorch.aar.sha256sums --acl public-read
0 commit comments