File tree Expand file tree Collapse file tree 2 files changed +18
-2
lines changed Expand file tree Collapse file tree 2 files changed +18
-2
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ version: 2.1
5
5
orbs :
6
6
macos : circleci/macos@2.3.3
7
7
ruby : circleci/ruby@2.0.0
8
-
8
+ aws-cli : circleci/aws-cli@3.1.4
9
9
10
10
default-executor : &default-executor
11
11
macos :
@@ -14,7 +14,6 @@ default-executor: &default-executor
14
14
environment :
15
15
FL_OUTPUT_DIR : output
16
16
17
-
18
17
jobs :
19
18
build-test-ios :
20
19
<< : *default-executor
48
47
- " 1d:f2:37:1e:7e:38:02:e0:76:2d:6a:a8:47:2e:85:09"
49
48
- checkout
50
49
- ruby/install-deps
50
+ - aws-cli/setup :
51
+ role-arn : $AWS_OIDC_ROLE_ARN
52
+ role-session-name : " ${CIRCLE_WORKFLOW_JOB_ID}.release"
53
+ session-duration : ' 900'
51
54
- run :
52
55
name : Publish new version to cocoapods trunk
53
56
command : bundle exec fastlane ios release
@@ -78,6 +81,8 @@ workflows:
78
81
requires :
79
82
- build-test-ios
80
83
- build-test-macos
84
+ context : amplify-swift-aws-oidc
85
+
81
86
- publish-doc :
82
87
filters :
83
88
branches :
Original file line number Diff line number Diff line change
1
+ require 'json'
2
+
1
3
PODSPEC_PATH = "AmplifyUtilsNotifications.podspec"
2
4
CHANGELOG_PATH = "CHANGELOG.md"
3
5
@@ -103,6 +105,15 @@ platform :ios do
103
105
104
106
desc "Publish new version to cocoapod trunck"
105
107
private_lane :publish_to_cocoapod_trunk do
108
+ # Define `COCOAPODS_TRUNK_TOKEN` env var for trunk authentication
109
+ # https://github.com/CocoaPods/cocoapods-trunk/commit/9e6ec1c1faf96fa837dc2ed70b5f54006b181ed6
110
+ secret = sh (
111
+ command : 'aws secretsmanager get-secret-value --secret-id ${COCOAPODS_SECRET_ARN}' ,
112
+ log : false
113
+ )
114
+
115
+ ENV [ 'COCOAPODS_TRUNK_TOKEN' ] = JSON . parse ( secret ) [ "SecretString" ]
116
+
106
117
pod_push (
107
118
use_bundle_exec : true ,
108
119
allow_warnings : true ,
You can’t perform that action at this time.
0 commit comments