Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker Container #67

Closed
jimmysong opened this issue Oct 1, 2018 · 9 comments
Closed

Docker Container #67

jimmysong opened this issue Oct 1, 2018 · 9 comments

Comments

@jimmysong
Copy link

It would be really useful if the whole thing ran as a docker container. You need to install docker anyway, might as well make it so that we can build a docker image and run it anywhere.

@prusnak
Copy link
Member

prusnak commented Oct 1, 2018

It is available from here: https://github.com/trezor/blockbook/tree/master/build/docker/bin

@prusnak prusnak closed this as completed Oct 1, 2018
@martinboehm
Copy link
Contributor

Actually, this is a build docker container, which produces debian packages for backend and blockbook. However, if I understand the issue correctly, the request is for a docker container, which would run the backend and blockbook. As this is not our use case - we run the software directly on server without docker, we are currently not providing this docker container. If @jimmysong creates a PR containing the runtime docker container, we will certainly merge it for others to use.

@jimmysong
Copy link
Author

I think your users would like to have their own blockbook server to run their trezor against and not leak privacy. Do you not think this is worth doing?

@prusnak
Copy link
Member

prusnak commented Oct 2, 2018

It is definitively worth doing. It should be very easy to adapt the builder Dockerfile and we'll give you a helping hand you might need when you hit any issues with that.

OTOH, blockbook is a Go project so the resulting binary is self-contained without any depedencies and it should be possible to run it without any problems on any distribution.

For the sake of completeness, there is another effort to docker-ize the blockbook here: SatoshiPortal/dockers#4

@prusnak prusnak reopened this Oct 2, 2018
@gustavocoding
Copy link

I've recently created a docker image for Blockbook and been using it with my Trezor.
It's an automated build hosted on docker hub, so if you wanna try, no need to build the image locally, just launch the container with a one-liner. More info on https://hub.docker.com/r/gustavonalle/blockbook/

Of course you can build the image locally if you want: https://github.com/gustavonalle/blockbook-docker

@martinboehm
Copy link
Contributor

Thank you very much for your superb contribution!
Would it be possible to update it so that it uses our build script, i.e https://github.com/trezor/blockbook/blob/master/build/docker/bin/Dockerfile, so that the build uses the pinned golang and rocksdb versions? It would also be forward compatible with modifications we do to our build process in the future.

@gustavocoding
Copy link

gustavocoding commented Dec 29, 2018

Pinning Golang and rocksdb versions is trivial.

Regarding using the build script, as it's in fact a Dockerfile that includes another Dockerfile, I'd need to extend those images, that would not work with Dockerhub build automation where a single Dockerfile must be provided.

In my case, I opted to do a manual build instead, since it's simpler and the resulting image size is considerably smaller: it is less than 500 Mb since I can execute several operations in the same Docker RUN instruction, which include the removal of temporary files.

@jorijn
Copy link

jorijn commented Oct 19, 2019

Since I couldn't get the image of @gustavonalle running due to permission errors I decided to set up a new Dockerfile based on the building Dockerfile provided by @martinboehm. I'd like to provide a starting point for someone to clean this up and submit a pull request for this repository with matching documentation:

I have this running locally against a bitcoin-core back-end. If this someone needs any additional information, feel free to reach out to me!

@gustavocoding
Copy link

Please see gustavocoding/blockbook-docker#1 (comment)
the issue was a misconfiguration on your side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants