File tree Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Original file line number Diff line number Diff line change 1
1
FROM ubuntu:18.04
2
2
3
- ARG snetd_version="v0.1.7"
4
-
5
3
ENV SINGNET_REPOS=/opt/singnet
6
4
7
5
RUN mkdir -p ${SINGNET_REPOS}
8
6
9
7
RUN apt-get update && \
10
8
apt-get install -y \
9
+ curl \
11
10
nano \
12
11
git \
13
12
wget
14
13
15
14
RUN apt-get install -y python3 python3-pip
16
15
17
- RUN cd ${SINGNET_REPOS} && \
18
- mkdir snet-daemon && \
19
- cd snet-daemon && \
20
- wget https://github.com/singnet/snet-daemon/releases/download/${snetd_version}/snet-daemon-${snetd_version}-linux-amd64.tar.gz && \
21
- tar -xvf snet-daemon-${snetd_version}-linux-amd64.tar.gz && \
22
- mv snet-daemon-${snetd_version}-linux-amd64/snetd /usr/bin/snetd
16
+ RUN SNETD_VERSION=`curl -s https://api.github.com/repos/singnet/snet-daemon/releases/latest | grep -oP '"tag_name": "\K (.*)(?=")' ` && \
17
+ cd /tmp && \
18
+ wget https://github.com/singnet/snet-daemon/releases/download/${SNETD_VERSION}/snet-daemon-${SNETD_VERSION}-linux-amd64.tar.gz && \
19
+ tar -xvf snet-daemon-${SNETD_VERSION}-linux-amd64.tar.gz && \
20
+ mv snet-daemon-${SNETD_VERSION}-linux-amd64/snetd /usr/bin/snetd
23
21
24
22
RUN cd ${SINGNET_REPOS} && \
25
23
git clone https://github.com/singnet/example-service.git && \
Original file line number Diff line number Diff line change @@ -102,12 +102,10 @@ python3 run_example_service.py
102
102
103
103
##### Running Service + Daemon in Docker Container
104
104
105
- * Build the docker image (with proper ` SNET Daemon ` version) and run a Container from it:
105
+ * Build the docker image and run a container from it:
106
106
107
107
```
108
- SNETD_VERSION="v0.1.7"
109
108
docker build \
110
- --build-arg snetd_version=$SNETD_VERSION \
111
109
-t snet_example_service \
112
110
https://github.com/singnet/example-service.git#master
113
111
You can’t perform that action at this time.
0 commit comments