This repository was archived by the owner on Mar 23, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 5 files changed +29
-45
lines changed Expand file tree Collapse file tree 5 files changed +29
-45
lines changed Original file line number Diff line number Diff line change 93
93
- install_rust
94
94
- install_node_devlibs
95
95
- print_current_versions
96
+ - setup_remote_docker
96
97
- run :
97
- name : " Package & Publish Release on GitHub"
98
+ name : " Package & Publish Release on GitHub and Docker Hub "
98
99
command : |
99
100
set -v
100
101
VERSION=$(cargo pkgid -- cnd|cut -d# -f2)
@@ -108,6 +109,12 @@ jobs:
108
109
ls ~/package/
109
110
ghr -t ${GITHUB_TOKEN_FOR_RELEASES} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -c ${CIRCLE_SHA1} -delete ${VERSION} ~/package/
110
111
112
+ echo $DOCKER_HUB_TOKEN | docker login -u thomaseizinger --password-stdin
113
+
114
+ docker build . -t comitnetwork/cnd:${VERSION} -t comitnetwork/cnd:latest
115
+ docker push comitnetwork/cnd:${VERSION}
116
+ docker push comitnetwork/cnd:latest
117
+
111
118
commands :
112
119
install_node_devlibs :
113
120
steps :
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1
- target /
2
- .circleci /
3
- .dependabot /
4
- .githooks /
5
- api_tests /
6
- .docker /Dockerfile
1
+ # The only thing we are interested in the Dockerfile is the release binary, hence we can ignore everything else to speed up the build process
2
+ *
3
+ ! target /release /cnd
Original file line number Diff line number Diff line change
1
+ FROM debian:buster
2
+
3
+ RUN apt-get update && \
4
+ apt-get install -y \
5
+ tini \
6
+ && rm -rf /var/lib/apt/lists/*
7
+
8
+ RUN useradd --create-home --shell /bin/bash cnd
9
+ USER cnd
10
+
11
+ COPY ./target/release/cnd /usr/local/bin
12
+
13
+ EXPOSE 9939
14
+ EXPOSE 8000
15
+
16
+ # tini allows us to CTRL+C our container if it runs in the foreground
17
+ ENTRYPOINT ["tini" ]
18
+ CMD ["cnd" ]
You can’t perform that action at this time.
0 commit comments