Skip to content

Commit 7e3c5d2

Browse files
committed
test more cli
1 parent db91bd0 commit 7e3c5d2

File tree

1 file changed

+15
-2
lines changed

1 file changed

+15
-2
lines changed

.github/workflows/test.yml

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,16 +14,29 @@ jobs:
1414
- name: Checkout
1515
uses: actions/checkout@v3
1616
- name: get credentials
17+
id: get-credentials
1718
uses: ./ # Uses an action in the root directory
1819
with:
1920
role-arn-to-assume: '${{ secrets.ROLE_ARN }}'
2021
oidc-provider-arn: '${{ secrets.OIDC_ARN }}'
2122

22-
- name: test aliyun cli
23+
- name: test aliyun cli (using env)
24+
env:
25+
ALIBABACLOUD_REGION_ID: ap-southeast-1
2326
run: |
2427
set -e
2528
wget https://github.com/aliyun/aliyun-cli/releases/download/v3.0.133/aliyun-cli-linux-3.0.133-amd64.tgz --no-verbose
2629
tar zxvf aliyun-cli-linux-3.0.133-amd64.tgz
2730
chmod +x ./aliyun
28-
export ALIBABACLOUD_REGION_ID=ap-southeast-1
2931
./aliyun sts GetCallerIdentity | jq .IdentityType
32+
33+
- name: test oss cli (using outputs)
34+
run: |
35+
set -e
36+
wget https://gosspublic.alicdn.com/ossutil/1.7.14/ossutil64 --no-verbose
37+
chmod +x ossutil64
38+
./ossutil64 --access-key-id ${{ steps.get-credentials.outputs.access-key-id }} \
39+
--access-key-secret ${{ steps.get-credentials.outputs.access-key-secret }} \
40+
--sts-token ${{ steps.get-credentials.outputs.security-token }} --mode StsToken \
41+
--endpoint oss-ap-southeast-1.aliyuncs.com \
42+
stat oss://${{ secrets.OSS_BUCKET }} | grep ACL

0 commit comments

Comments
 (0)