immutability-io / vault-ethereum

A plugin that turns Vault into an Ethereum wallet.
244 stars 66 forks source link

Breaking change for github.com/miguelmota/go-coinmarketcap ? #47

Closed Nayir closed 5 years ago

Nayir commented 6 years ago

Detailed Description

I've got an issu with my docker installation. This is my DockerFile

FROM vault:latest
RUN apk add --update alpine-sdk \
    && mkdir /vault/plugins \
    && apk update \
    && apk add go git \ 
    && go get github.com/immutability-io/vault-ethereum \
    && go build github.com/immutability-io/vault-ethereum \
    && mv /root/go/bin/vault-ethereum /vault/plugins/vault-ethereum \
    && export SHASUM256_eth=$(sha256sum "/vault/plugins/vault-ethereum" | cut -d' ' -f1) \
    && echo  \"plugin_directory\" = \"/vault/plugins\" > /vault/config/plugin.json

Then, i've got an error with go-coinmarketcap

package github.com/miguelmota/go-coinmarketcap: no Go files in /root/go/src/github.com/miguelmota/go-coinmarketcap

There is some breaking change since the last update ? There is any way to avoid this error during the build of vault-ethereum-plugin on Docker ?

Thanks a lot

Your Environment

cypherhat commented 6 years ago

Thanks for reporting this.

This is a double problem. First, the coinmarketcap API will change soon. The free version will disappear very soon.

I will refactor in the following way:

  1. If you provide an api_key for the config, then I will use it to talk to the PRO version of the coinmarketcap API.

  2. If the api_key is missing, I won't call the coinmarketcap API.

I admit this is a bit hokey, but I have to get this done soon. And release a new build.

cypherhat commented 6 years ago

I think I've made it better now... I tested via go get -v github.com/immutability-io/vault-ethereum and things don't bork.

I am not super happy with the way I am baking exchange rates into the various APIs at the moment - that is a bad design. I will be changing that later this week/weekend.

But for now, you should be good. Please let me know if your docker build succeeds.