-
Notifications
You must be signed in to change notification settings - Fork 0
60 lines (50 loc) · 1.43 KB
/
image_test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: Custom Docker Image Example
on: push
jobs:
build:
runs-on: ubuntu-latest
container:
image: registry.cn-shanghai.aliyuncs.com/dango/android_ci:latest # 指定您的自定义 Docker 镜像及其标签
options: --platform linux/amd64
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Run a custom command in the custom image
run: |
echo "Hello from the custom Docker image!"
env
ls -a
echo " ---- ---- "
pwd
- name: Build and package
run: |
# Your build commands here
mkdir dist
echo "Hello, world!" > dist/hello.txt
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: my-artifacts
path: dist
deploy:
needs: build
runs-on: ubuntu-latest
container:
image: registry.cn-shanghai.aliyuncs.com/dango/android_ci:latest # 指定您的自定义 Docker 镜像及其标签
options: --platform linux/amd64
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Download Artifacts
uses: actions/download-artifact@v2
with:
name: my-artifacts
- name: 打印文件
run: |
env
ls -a
pwd
- name: Deploy
run: |
# Use the downloaded artifacts for deployment
cat hello.txt