forked from bekriebel/balena-cli-action
-
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathDockerfile
30 lines (25 loc) · 1023 Bytes
/
Dockerfile
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
FROM debian:buster-slim
LABEL Description="Use the Balena CLI to perform actions"
# Get the latest Balena release using
# curl -s https://api.github.com/repos/balena-io/balena-cli/releases/latest | jq -r .tag_name)
# Install the standalone balena-cli package
RUN apt-get update && apt-get install -y \
curl \
unzip && \
cd /opt/ && \
export BALENA_RELEASE="v20.2.3" && \
echo "Uses Balena CLI version: $BALENA_RELEASE" && \
curl -O -sSL "https://github.com/balena-io/balena-cli/releases/download/$BALENA_RELEASE/balena-cli-$BALENA_RELEASE-linux-x64-standalone.zip" && \
unzip balena-cli-*-linux-x64-standalone.zip && \
ln -s /opt/balena-cli/balena /usr/bin/ && \
apt-get purge -y \
curl \
unzip && \
apt-get autoremove -y && \
rm -rf \
balena-cli-*-linux-x64-standalone.zip \
/var/lib/apt/lists/*
# Copy entrypoint into `/opt`
COPY entrypoint.sh /opt/entrypoint.sh
# Code file to execute when the docker container starts up (`entrypoint.sh`)
ENTRYPOINT ["/opt/entrypoint.sh"]