File tree 5 files changed +22
-6
lines changed
5 files changed +22
-6
lines changed Original file line number Diff line number Diff line change 42
42
- uses : actions/checkout@v2
43
43
with :
44
44
submodules : true
45
+ - name : Get branch name
46
+ id : branch-name
47
+ uses :
tj-actions/[email protected]
45
48
- name : Build Docker Image
46
- run : docker build --tag opendr-toolkit:cpu_$OPENDR_VERSION --file Dockerfile .
49
+ run : docker build --tag opendr-toolkit:cpu_$OPENDR_VERSION --build-arg branch=${{ steps.branch-name.outputs.current_branch }} -- file Dockerfile .
47
50
- name : Login to Docker Hub
48
51
uses : docker/login-action@v1
49
52
with :
59
62
- uses : actions/checkout@v2
60
63
with :
61
64
submodules : true
65
+ - name : Get branch name
66
+ id : branch-name
67
+ uses :
tj-actions/[email protected]
62
68
- name : Build Docker Image
63
- run : docker build --tag opendr-toolkit:cuda_$OPENDR_VERSION --file Dockerfile-cuda .
69
+ run : docker build --tag opendr-toolkit:cuda_$OPENDR_VERSION --build-arg branch=${{ steps.branch-name.outputs.current_branch }} -- file Dockerfile-cuda .
64
70
- name : Login to Docker Hub
65
71
uses : docker/login-action@v1
66
72
with :
Original file line number Diff line number Diff line change @@ -139,9 +139,12 @@ jobs:
139
139
- uses : actions/checkout@v2
140
140
with :
141
141
submodules : true
142
+ - name : Get branch name
143
+ id : branch-name
144
+ uses :
tj-actions/[email protected]
142
145
- name : Build image
143
146
run : |
144
- docker build --tag opendr/opendr-toolkit:cpu_test --file Dockerfile .
147
+ docker build --tag opendr/opendr-toolkit:cpu_test --build-arg branch=${{ steps.branch-name.outputs.current_branch }} -- file Dockerfile .
145
148
docker save opendr/opendr-toolkit:cpu_test > cpu_test.zip
146
149
- name : Upload image artifact
147
150
uses : actions/upload-artifact@v2
Original file line number Diff line number Diff line change @@ -143,9 +143,12 @@ jobs:
143
143
with :
144
144
submodules : true
145
145
ref : develop
146
+ - name : Get branch name
147
+ id : branch-name
148
+ uses :
tj-actions/[email protected]
146
149
- name : Build image
147
150
run : |
148
- docker build --tag opendr/opendr-toolkit:cpu_test --file Dockerfile .
151
+ docker build --tag opendr/opendr-toolkit:cpu_test --build-arg branch=${{ steps.branch-name.outputs.current_branch }} -- file Dockerfile .
149
152
docker save opendr/opendr-toolkit:cpu_test > cpu_test.zip
150
153
- name : Upload image artifact
151
154
uses : actions/upload-artifact@v2
Original file line number Diff line number Diff line change 1
1
FROM ubuntu:20.04
2
2
3
+ ARG branch
4
+
3
5
# Install dependencies
4
6
RUN apt-get update && \
5
7
apt-get --yes install git sudo
@@ -12,7 +14,7 @@ RUN chmod +x /tini
12
14
ENTRYPOINT ["/tini" , "--" ]
13
15
14
16
# Clone the repo and install the toolkit
15
- RUN git clone --depth 1 --recurse-submodules -j8 https://github.com/opendr-eu/opendr
17
+ RUN git clone --depth 1 --recurse-submodules -j8 https://github.com/opendr-eu/opendr -b $branch
16
18
WORKDIR "/opendr"
17
19
RUN ./bin/install.sh
18
20
Original file line number Diff line number Diff line change 1
1
FROM nvidia/cuda:11.0-base
2
2
3
+ ARG branch
4
+
3
5
# Install dependencies
4
6
RUN apt-get update && \
5
7
apt-get --yes install git sudo apt-utils
@@ -43,7 +45,7 @@ RUN sudo apt-get --yes install build-essential && \
43
45
44
46
# Clone the repo and install the toolkit
45
47
ENV OPENDR_DEVICE gpu
46
- RUN git clone --depth 1 --recurse-submodules -j8 https://github.com/opendr-eu/opendr
48
+ RUN git clone --depth 1 --recurse-submodules -j8 https://github.com/opendr-eu/opendr -b $branch
47
49
WORKDIR "/opendr"
48
50
RUN ./bin/install.sh
49
51
You can’t perform that action at this time.
0 commit comments