decred / dcrdocker Goto Github PK
View Code? Open in Web Editor NEWDockerfiles for Decred.
License: ISC License
Dockerfiles for Decred.
License: ISC License
Mind updating the published Dockerfile-dcrd to use latest release v1.2.0? Thanks!
https://github.com/decred/dcrdocker/blob/master/Dockerfile-dcrd#L11
When I build the dcrd from source I get a few more binaries.
-rwxr-xr-x 1 decred decred 10191247 Aug 23 22:30 addblock
-rwxr-xr-x 1 decred decred 11210318 Aug 23 22:30 dcrctl
-rwxr-xr-x 1 decred decred 18829982 Aug 23 22:31 dcrd
-rwxr-xr-x 1 decred decred 9961906 Aug 23 22:30 findcheckpoint
-rwxr-xr-x 1 decred decred 4697431 Aug 23 22:30 gencerts
-rwxr-xr-x 1 decred decred 1979881 Aug 23 22:30 promptsecret
However, in the image only the dcrd binary exist.
decred@c8784b9f758a:~$ pwd
/home/decred
decred@c8784b9f758a:~$ ls -l
total 19064
-rwxr-xr-x 1 decred decred 19518723 Apr 25 20:02 dcrd
Line 44 in 2ec5be3
dcrdata is switching to golangci-lint instead of gometalinter. With modules golangci-lint appears to work correctly.
The snippet I'm currently using in dcrdata's run_test.sh file is:
git clone --branch v1.12.3 https://github.com/golangci/golangci-lint ~/golangci-lint
pushd ~/golangci-lint/cmd/golangci-lint
go install
popd
I am using it as follows:
golangci-lint run --deadline=10m --disable-all --enable govet --enable staticcheck \
--enable gosimple --enable unconvert --enable ineffassign --enable structcheck \
--enable goimports --enable misspell --enable unparam
if [ $? != 0 ]; then
echo 'golangci-lint has some complaints'
exit 1
fi
There seems to be no need to install individual linters.
I am creating some docker-compose files for dcrdata and need the validate that dcrd is up and running through a healthcheck. However, there is no curl command. Please add the curl package to the list of packages during a build.
Requested by @dajohi
I build a docker image locally by this Dockerfile Dockerfile-insight , then I run a container by this images I just built, error occured as following:
> [email protected] start /home/insight/insight
> INSIGHT_FORCE_RPC_SYNC=1 INSIGHT_PUBLIC_PATH=public node node_modules/.bin/insight-bitcore-api
/home/insight/insight/node_modules/insight-bitcore-api/node_modules/winston/lib/winston.js:10
const logform = require('logform');
^^^^^
SyntaxError: Use of const in strict mode.
at Module._compile (module.js:439:25)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.<anonymous> (/home/insight/insight/node_modules/insight-bitcore-api/lib/logger.js:1:77)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
npm ERR! [email protected] start: `INSIGHT_FORCE_RPC_SYNC=1 INSIGHT_PUBLIC_PATH=public node node_modules/.bin/insight-bitcore-api`
npm ERR! Exit status 8
npm ERR!
npm ERR! Failed at the [email protected] start script.
npm ERR! This is most likely a problem with the insight-bitcore package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! INSIGHT_FORCE_RPC_SYNC=1 INSIGHT_PUBLIC_PATH=public node node_modules/.bin/insight-bitcore-api
npm ERR! You can get their info via:
npm ERR! npm owner ls insight-bitcore
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 4.9.87-linuxkit-aufs
npm ERR! command "/home/insight/.nvm/v0.10.40/bin/node" "/home/insight/.nvm/v0.10.40/bin/npm" "start"
npm ERR! cwd /home/insight/insight
npm ERR! node -v v0.10.40
npm ERR! npm -v 1.4.28
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/insight/insight/npm-debug.log
npm ERR! not ok code 0
While,I can run container by official image decred/decred-insight
. So my question is: Does the decred/decred-insight
image built from this Dockerfile? Or, maybe this Dockerfile is sth wrong?
I am trying to create a more lightweight version of decred using alpine
instead of ubuntu
.
To simplify getting it to work, I have this Dockerfile
FROM alpine:3.6
RUN apk update \
&& apk add libc6-compat curl \
&& curl -LO https://github.com/decred/decred-binaries/releases/download/v1.0.5/decred-linux-amd64-v1.0.5.tar.gz \
&& tar xzf decred-linux-amd64-v1.0.5.tar.gz
The libc6-compat
library is needed because I will get an No such file or directory
when trying to execute decred
binaries without (because of missing /lib64/ld-linux-x86-64.so.2
, see readelf -a dcrwallet | grep "Requesting program interpreter"
).
Now I am getting this error:
Error relocating ./dcrwallet: __vfprintf_chk: symbol not found
Error relocating ./dcrwallet: __fprintf_chk: symbol not found
which I think is some missing flags during the compilation.
Is there any hope getting this worked out without having to make an alpine image that compiles it all from scratch?
The absolute best and most secure docker image would be using the scratch
base image. Something like https://blog.codeship.com/building-minimal-docker-containers-for-go-applications/, but changing from ubuntu to alpine is also good..
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.