Closed marcofranssen closed 5 years ago
I don't know docker but it seems like the file system wasn't transferred over. So in the Dockerfile I added ADD . /go/src/gocryptotrader
on line 2 and I replaced RUN dep ensure -vendor-only
with RUN dep ensure -update
, it seems to build after that, I don't know effectively though.
Sending build context to Docker daemon 35.95MB
Step 1/15 : FROM golang:1.9.4 as build
---> a6c306bd0b2f
Step 2/15 : ADD . /go/src/gocryptotrader
---> b4a3c97cb199
Step 3/15 : RUN curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
---> Running in f3fcaa9e0d1d
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 5110 100 5110 0 0 8652 0 --:--:-- --:--:-- --:--:-- 8646
ARCH = amd64
OS = linux
Will install into /go/bin
Fetching https://github.com/golang/dep/releases/latest..
Release Tag = v0.5.0
Fetching https://github.com/golang/dep/releases/tag/v0.5.0..
Fetching https://github.com/golang/dep/releases/download/v0.5.0/dep-linux-amd64..
Setting executable permissions.
Moving executable to /go/bin/dep
Removing intermediate container f3fcaa9e0d1d
---> 808739f89657
Step 4/15 : WORKDIR /go/src/gocryptotrader
Removing intermediate container 9b0a9b8496c3
---> 0fb82eb8d2cf
Step 5/15 : COPY Gopkg.* ./
---> db5429ef6214
Step 6/15 : RUN ls
---> Running in b18ca844e6b6
CONTRIBUTORS
Dockerfile
Gopkg.lock
Gopkg.toml
LICENSE
Makefile
README.md
common
communications
config
config.json
config_example.json
currency
docker-compose.yml
events
exchange.go
exchange_test.go
exchanges
gocryptotrader
helpers.go
helpers_test.go
main.go
main_test.go
node_modules
portfolio
restful_router.go
restful_server.go
routines.go
testdata
tools
vendor
version.go
websocket.go
Removing intermediate container b18ca844e6b6
---> 8d0d39243e2e
Step 7/15 : RUN dep ensure -update
---> Running in 626a0ced2e46
Removing intermediate container 626a0ced2e46
---> 37fb0546d35f
Step 8/15 : COPY . .
---> fa096fb9ca74
Step 9/15 : RUN mv -vn config_example.json config.json && GOARCH=386 GOOS=linux CGO_ENABLED=0 go install -v && mv /go/bin/linux_386 /go/bin/gocryptotrader
---> Running in e2c120899020
runtime/internal/sys
runtime/internal/atomic
runtime
internal/race
sync/atomic
errors
unicode
unicode/utf8
encoding
math
unicode/utf16
math/bits
container/list
crypto/subtle
crypto/internal/cipherhw
internal/nettrace
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/symbol
sync
io
internal/singleflight
syscall
bytes
crypto/cipher
hash
strings
hash/crc32
crypto/hmac
strconv
math/rand
gocryptotrader/vendor/golang.org/x/crypto/pbkdf2
bufio
vendor/golang_org/x/text/transform
path
html
encoding/base64
reflect
crypto/aes
crypto
crypto/rc4
crypto/sha512
crypto/md5
crypto/sha1
crypto/sha256
time
internal/syscall/unix
gocryptotrader/vendor/golang.org/x/crypto/scrypt
internal/poll
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/nonce
os
os/signal
fmt
sort
encoding/binary
encoding/pem
path/filepath
regexp/syntax
crypto/des
vendor/golang_org/x/crypto/chacha20poly1305/internal/chacha20
vendor/golang_org/x/crypto/poly1305
vendor/golang_org/x/crypto/curve25519
vendor/golang_org/x/crypto/chacha20poly1305
io/ioutil
encoding/json
encoding/hex
context
vendor/golang_org/x/net/http2/hpack
math/big
flag
compress/flate
log
vendor/golang_org/x/text/unicode/bidi
net
vendor/golang_org/x/text/unicode/norm
net/url
mime
vendor/golang_org/x/text/secure/bidirule
mime/quotedprintable
net/http/internal
compress/gzip
regexp
encoding/csv
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/base
encoding/gob
text/template/parse
gocryptotrader/vendor/github.com/streamrail/concurrent-map
vendor/golang_org/x/net/idna
crypto/rand
crypto/elliptic
encoding/asn1
crypto/dsa
text/template
crypto/rsa
crypto/x509/pkix
crypto/ecdsa
html/template
crypto/x509
vendor/golang_org/x/net/lex/httplex
vendor/golang_org/x/net/proxy
net/textproto
mime/multipart
crypto/tls
net/http/httptrace
net/smtp
net/http
gocryptotrader/vendor/github.com/gorilla/mux
gocryptotrader/vendor/github.com/gorilla/websocket
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/common
gocryptotrader/vendor/golang.org/x/net/websocket
net/rpc
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/currencyconverterapi
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/currencylayer
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/fixer.io
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/openexchangerates
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/pair
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/portfolio
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/request
gocryptotrader/vendor/github.com/ugorji/go/codec
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/orderbook
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/ticker
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/translation
gocryptotrader/vendor/github.com/toorop/go-pusher
gocryptotrader/vendor/github.com/thrasher-/socketio
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/stats
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/config
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/base
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/slack
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/telegram
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/smtpservice
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/smsglobal
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/anx
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/binance
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bitfinex
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bitflyer
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bithumb
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bitstamp
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bittrex
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/btcc
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/btcmarkets
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/coinbasepro
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/coinut
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/exmo
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/gemini
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/huobi
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/itbit
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/kraken
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/lakebtc
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/liqui
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/localbitcoins
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/okcoin
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/okex
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/wex
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/yobit
gocryptotrader/vendor/github.com/beatgammit/turnpike
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/hitbtc
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/poloniex
gocryptotrader
Removing intermediate container e2c120899020
---> 12286539735a
Step 10/15 : FROM alpine:latest
---> 11cd0b38bc3c
Step 11/15 : RUN apk update && apk add --no-cache ca-certificates
---> Using cache
---> 190f83fba796
Step 12/15 : COPY --from=build /go/bin/gocryptotrader /app/
---> Using cache
---> 966947e39a3f
Step 13/15 : COPY --from=build /go/src/gocryptotrader/config.json /app/
---> Using cache
---> 68a5c2c57084
Step 14/15 : EXPOSE 9050
---> Using cache
---> f1c04b9f849f
Step 15/15 : CMD ["/app/gocryptotrader"]
---> Using cache
---> 30e9f9b0c92d
Successfully built 30e9f9b0c92d
Commit https://github.com/thrasher-/gocryptotrader/commit/6b575dd92573842188f97c72ff238d15a0d0f0fc should fix this
Building cli
Step 1/12 : FROM golang:1.10 as build
---> d0e7a411e3da
Step 2/12 : RUN curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
---> Using cache
---> 8dcc5ed817ca
Step 3/12 : WORKDIR /go/src/gocryptotrader
---> Using cache
---> bf2f30cf730a
Step 4/12 : COPY . .
---> 9fcdc87b7a49
Step 5/12 : RUN dep ensure
---> Running in 1f6d008974d8
Removing intermediate container 1f6d008974d8
---> 7e9379d973fe
Step 6/12 : RUN mv -vn config_example.json config.json && GOARCH=386 GOOS=linux CGO_ENABLED=0 go install -v && mv /go/bin/linux_386 /go/bin/gocryptotrader
---> Running in d97f616b3288
'config_example.json' -> 'config.json'
errors
internal/race
runtime/internal/atomic
runtime/internal/sys
sync/atomic
unicode
runtime
unicode/utf8
encoding
math
strconv
internal/testlog
unicode/utf16
math/bits
container/list
crypto/subtle
crypto/internal/cipherhw
crypto/rc4
vendor/golang_org/x/crypto/cryptobyte/asn1
internal/nettrace
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/symbol
sync
io
reflect
bytes
syscall
time
encoding/binary
internal/poll
encoding/base64
sort
os
strings
bufio
fmt
hash
hash/crc32
crypto/cipher
encoding/json
flag
context
compress/flate
crypto/aes
internal/syscall/unix
math/rand
compress/gzip
math/big
crypto
crypto/des
crypto/sha512
crypto/hmac
crypto/md5
crypto/sha1
crypto/sha256
encoding/hex
encoding/pem
crypto/rand
crypto/elliptic
encoding/asn1
crypto/rsa
crypto/ecdsa
crypto/dsa
crypto/x509/pkix
vendor/golang_org/x/crypto/cryptobyte
path/filepath
io/ioutil
internal/singleflight
net
net/url
vendor/golang_org/x/crypto/chacha20poly1305/internal/chacha20
vendor/golang_org/x/crypto/poly1305
vendor/golang_org/x/crypto/chacha20poly1305
vendor/golang_org/x/crypto/curve25519
vendor/golang_org/x/net/http2/hpack
vendor/golang_org/x/text/transform
log
vendor/golang_org/x/text/unicode/bidi
vendor/golang_org/x/text/secure/bidirule
vendor/golang_org/x/text/unicode/norm
crypto/x509
vendor/golang_org/x/net/idna
vendor/golang_org/x/net/lex/httplex
crypto/tls
vendor/golang_org/x/net/proxy
mime
mime/quotedprintable
net/textproto
mime/multipart
net/http/internal
path
net/http/httptrace
regexp/syntax
net/http
regexp
encoding/csv
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/base
gocryptotrader/vendor/golang.org/x/crypto/pbkdf2
gocryptotrader/vendor/golang.org/x/crypto/scrypt
net/smtp
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/nonce
gocryptotrader/vendor/github.com/streamrail/concurrent-map
encoding/gob
html
text/template/parse
text/template
html/template
gocryptotrader/vendor/github.com/gorilla/mux
gocryptotrader/vendor/github.com/gorilla/websocket
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/common
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/currencyconverterapi
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/currencylayer
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/fixer.io
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider/openexchangerates
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/pair
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/forexprovider
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/portfolio
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/orderbook
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/ticker
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/config
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/currency/translation
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/request
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/base
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/slack
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/smsglobal
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/smtpservice
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications/telegram
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/communications
gocryptotrader/vendor/golang.org/x/net/websocket
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/anx
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/binance
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bitfinex
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bitflyer
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bithumb
gocryptotrader/vendor/github.com/toorop/go-pusher
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bitstamp
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/bittrex
gocryptotrader/vendor/github.com/thrasher-/socketio
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/btcmarkets
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/btcc
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/coinbasepro
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/coinut
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/exmo
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/gemini
net/rpc
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/huobi
gocryptotrader/vendor/github.com/ugorji/go/codec
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/itbit
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/kraken
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/lakebtc
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/liqui
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/localbitcoins
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/okcoin
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/okex
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/stats
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/wex
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/yobit
os/signal
gocryptotrader/vendor/github.com/beatgammit/turnpike
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/hitbtc
gocryptotrader/vendor/github.com/thrasher-/gocryptotrader/exchanges/poloniex
gocryptotrader
Removing intermediate container d97f616b3288
---> b830425b5dce
Step 7/12 : FROM alpine:latest
---> 11cd0b38bc3c
Step 8/12 : RUN apk update && apk add --no-cache ca-certificates
---> Using cache
---> 43e6ef887d44
Step 9/12 : COPY --from=build /go/bin/gocryptotrader /app/
---> Using cache
---> 4aad8b2ec10e
Step 10/12 : COPY --from=build /go/src/gocryptotrader/config.json /app/
---> Using cache
---> 91d5b805a832
Step 11/12 : EXPOSE 9050
---> Using cache
---> 8556c2bc875a
Step 12/12 : CMD ["/app/gocryptotrader"]
---> Using cache
---> 78f25bddeba3
Successfully built 78f25bddeba3
Successfully tagged gocryptotrader_cli:latest
Building web
Step 1/12 : FROM node:9-alpine as build
---> a56170f59699
Step 2/12 : COPY package.json package-lock.json ./
---> Using cache
---> bed057cb6a10
Step 3/12 : RUN npm set progress=false && npm config set depth 0 && npm cache clean --force
---> Using cache
---> 00dc23cc4713
Step 4/12 : RUN npm i && mkdir /app && cp -R ./node_modules /app
---> Using cache
---> f301b20c14d1
Step 5/12 : WORKDIR /app
---> Using cache
---> 3f56eaf419d5
Step 6/12 : COPY . .
---> Using cache
---> c8499536345b
Step 7/12 : RUN $(npm bin)/ng build --prod --build-optimizer
---> Using cache
---> 599dca0de7b6
Step 8/12 : FROM nginx:1.13.3-alpine
---> ba60b24dbad5
Step 9/12 : RUN rm -rf /var/www/html/*
---> Using cache
---> cf527e784e10
Step 10/12 : COPY nginx/default.conf /etc/nginx/conf.d/
---> Using cache
---> eccf5247a170
Step 11/12 : COPY --from=build /app/dist /var/www/html
---> Using cache
---> f2bf3f443938
Step 12/12 : CMD ["nginx", "-g", "daemon off;"]
---> Using cache
---> 0fe9c8e8c803
Successfully built 0fe9c8e8c803
Successfully tagged gocryptotrader_web:latest
Recreating gocryptotrader_cli_1 ... done
Recreating gocryptotrader_web_1 ... done
@thrasher- not exactly. I made some changes to the dockerfile in order to preserve the layers and not have them recreated every time.
Pls check my new PR: https://github.com/thrasher-/gocryptotrader/pull/165
Fix merged via #165
See below the build of the cli docker image is failing. Filing it as a bug over here so someone might be able to contribute. Tried quickly by upgrading to new
golang:1.10
tag but unfortunatily fails with same error.Problems seems to be with the
COPY . .
which does not copy all the source files into the container after a little further investigation.