schollz / cowyo

A feature-rich wiki webserver for minimalists :cow: :speech_balloon:
https://cowyo.com/
MIT License
920 stars 69 forks source link

Docker-compose Makefile Error #136

Closed EliCDavis closed 5 years ago

EliCDavis commented 6 years ago

Upon cloning the repository and running docker-compose up I receive the following error

root@heartburn:~/cowyo# docker-compose up -d
Creating network "cowyo_default" with the default driver
Building cowyo
Step 1/10 : FROM golang:1.9-alpine as builder
1.9-alpine: Pulling from library/golang
605ce1bd3f31: Already exists
f966ecaebdf4: Pull complete
ca1ad863697c: Pull complete
a65cca5cc6ad: Pull complete
b17475c0615c: Pull complete
09d316817793: Pull complete
6d660078289e: Pull complete
Digest: sha256:a9d5f1d5b138ae2266f1fbf548a2f56d1ee717fdcc3e7804a8de58cf060518c5
Status: Downloaded newer image for golang:1.9-alpine
 ---> 499696d18cfe
Step 2/10 : WORKDIR /go/src/cowyo
 ---> 6ae21b3cbd46
Removing intermediate container fdf7aa982c73
Step 3/10 : COPY . .
 ---> 77183568ec1d
Removing intermediate container 0bf818e3fb5b
Step 4/10 : ENV CGO_ENABLED 0
 ---> Running in 463fec346dc8
 ---> 85816ccc1e59
Removing intermediate container 463fec346dc8
Step 5/10 : RUN apk add --no-cache git make     && go get -u github.com/schollz/cowyo     && go get -u github.com/jteeuwen/go-bindata/...     && make     && apk del --purge git make     && rm -rf /var/cache/apk*
 ---> Running in 3da8d8cb0aaf
fetch http://dl-cdn.alpinelinux.org/alpine/v3.6/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.6/community/x86_64/APKINDEX.tar.gz
(1/6) Installing libssh2 (1.8.0-r1)
(2/6) Installing libcurl (7.60.0-r0)
(3/6) Installing expat (2.2.0-r1)
(4/6) Installing pcre (8.41-r0)
(5/6) Installing git (2.13.5-r0)
(6/6) Installing make (4.2.1-r0)
Executing busybox-1.26.2-r9.trigger
OK: 25 MiB in 18 packages
go build -ldflags "-X main.version=v2.11.0-19-g180a28c"
# cowyo
./main.go:63:10: cannot use logger(c.GlobalBool("debug")) (type *"cowyo/vendor/github.com/jcelliott/lumber".ConsoleLogger) as type *"github.com/schollz/cowyo/vendor/github.com/jcelliott/lumber".ConsoleLogger in argument to server.Serve
./main.go:167:53: cannot use logger(c.GlobalBool("debug")) (type *"cowyo/vendor/github.com/jcelliott/lumber".ConsoleLogger) as type *"github.com/schollz/cowyo/vendor/github.com/jcelliott/lumber".ConsoleLogger in argument to server.Migrate
make: *** [Makefile:9: build] Error 2
ERROR: Service 'cowyo' failed to build: The command '/bin/sh -c apk add --no-cache git make     && go get -u github.com/schollz/cowyo     && go get -u github.com/jteeuwen/go-bindata/...     && make     && apk del --purge git make     && rm -rf /var/cache/apk*' returned a non-zero code: 2
schollz commented 6 years ago

@DanielHeath Do you know what is happening here? Its a weird vendoring issue, but I don't really know what to make of it.

DanielHeath commented 6 years ago

I suspect it's because of go get -u github.com/schollz/cowyo in the Dockerfile.

That's putting a second checkout of cowyo into the docker container.

schollz commented 5 years ago

@EliCDavis Should be fixed now