File tree Expand file tree Collapse file tree 4 files changed +16
-19
lines changed Expand file tree Collapse file tree 4 files changed +16
-19
lines changed Original file line number Diff line number Diff line change 1
- 28
1
+ 29
Original file line number Diff line number Diff line change 11
11
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
12
# See the License for the specific language governing permissions and
13
13
# limitations under the License.
14
- FROM thyrlian/android-sdk:4.0 as android
14
+ FROM thyrlian/android-sdk:4.0 AS android
15
15
16
16
FROM ubuntu:22.04
17
17
18
- ENV DEBIAN_FRONTEND noninteractive
19
-
20
18
# Android
21
19
COPY --from=android /opt/android-sdk /opt/android-sdk
22
20
23
- ADD scripts/docker_install.sh /tmp/
24
- RUN /tmp/docker_install.sh
21
+ RUN --mount=target=/mnt,source=scripts DEBIAN_FRONTEND=noninteractive /mnt/docker_install.sh
25
22
26
23
# In this path executables will be installed during docker build
27
- ARG SYS_GOPATH /opt/go
28
- ENV PATH $ SYS_GOPATH/bin:/usr/local/go/bin:$PATH
24
+ ARG SYS_GOPATH= /opt/go
25
+ ENV PATH=${ SYS_GOPATH} /bin:/usr/local/go/bin:$PATH
29
26
30
- ADD Makefile /tmp/
31
- RUN GOPATH=$SYS_GOPATH make -C /tmp/ envinit
27
+ RUN --mount=target=/mnt/Makefile,source=Makefile GOPATH=${SYS_GOPATH} make -C /mnt envinit
32
28
33
- ENV PATH /opt/qt6/6.8.2/gcc_64/bin:/opt/qt6/6.8.2/gcc_64/libexec:$PATH
29
+ ENV PATH= /opt/qt6/6.8.2/gcc_64/bin:/opt/qt6/6.8.2/gcc_64/libexec:$PATH
34
30
35
31
CMD ["bash" ]
Original file line number Diff line number Diff line change @@ -82,8 +82,11 @@ clean:
82
82
cd frontends/qt && $(MAKE ) clean
83
83
cd frontends/android && $(MAKE ) clean
84
84
cd backend/mobileserver && $(MAKE ) clean
85
+
86
+ # The container image only supports amd64 bercause of "thyrlian/android-sdk"
87
+ # that downloads amd64 specific binaries
85
88
dockerinit :
86
- ./scripts/container.sh build --pull --force-rm -t shiftcrypto/bitbox-wallet-app .
89
+ ./scripts/container.sh build --platform linux/amd64 --pull -t shiftcrypto/bitbox-wallet-app: $( shell cat .containerversion) .
87
90
dockerdev :
88
91
./scripts/dockerdev.sh
89
92
locize-push :
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ if [ "$OS_NAME" == "linux" ]; then
12
12
# Which docker image to use to run the CI. Defaults to Docker Hub.
13
13
# Overwrite with CI_IMAGE=docker/image/path environment variable.
14
14
# Keep this in sync with .github/workflows/ci.yml.
15
- : " ${CI_IMAGE:= shiftcrypto/ bitbox-wallet-app: 26 } "
15
+ : " ${CI_IMAGE:= shiftcrypto/ bitbox-wallet-app: $(cat .containerversion) } "
16
16
# Time image pull to compare in the future.
17
17
time docker pull " $CI_IMAGE "
18
18
@@ -32,14 +32,12 @@ if [ "$OS_NAME" == "osx" ]; then
32
32
# GitHub CI installs Go and Qt directly in the macos action, before executing
33
33
# this script.
34
34
go version
35
- export GOPATH=~ /go
36
- export PATH=" $PATH :~/go/bin"
37
- mkdir -p $GOPATH /$( dirname $GO_SRC_DIR )
35
+ export PATH=" ~/go/bin:$PATH "
36
+ mkdir -p $( go env GOPATH) /$( dirname $GO_SRC_DIR )
38
37
# GitHub checkout action (git clone) seem to require current work dir
39
38
# to be the root of the repo during its clean up phase. So, we push it
40
39
# here and pop in the end.
41
- pushd ../ && cp -a bitbox-wallet-app $GOPATH /$( dirname $GO_SRC_DIR )
42
- cd $GOPATH /$GO_SRC_DIR
43
- make " $WHAT "
40
+ pushd ../ && cp -a bitbox-wallet-app $( go env GOPATH/) $( dirname $GO_SRC_DIR )
41
+ make -C $( go env GOPATH) /$GO_SRC_DIR " $WHAT "
44
42
popd
45
43
fi
You can’t perform that action at this time.
0 commit comments