Skip to content
This repository has been archived by the owner on Feb 24, 2024. It is now read-only.

Commit

Permalink
makes sure that both Dockerfile.build and Dockerfile get the latest (#…
Browse files Browse the repository at this point in the history
…1313)

package versions for their builds
  • Loading branch information
markbates authored Sep 20, 2018
1 parent 18a785a commit 93538a2
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 18 deletions.
6 changes: 1 addition & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,6 @@ ARG TRAVIS_TAG

RUN buffalo version

RUN go get -u github.com/alecthomas/gometalinter
RUN gometalinter --install

ENV BP=$GOPATH/src/github.com/gobuffalo/buffalo

RUN rm $(which buffalo)
Expand All @@ -26,8 +23,7 @@ RUN mkdir -p $BP
WORKDIR $BP
COPY . .

RUN go get github.com/gobuffalo/buffalo-pop
RUN make deps
RUN make ci-deps
RUN make install

RUN gometalinter --vendor --deadline=5m ./... --skip=internal
Expand Down
14 changes: 2 additions & 12 deletions Dockerfile.build
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM golang:latest
EXPOSE 3000
ENV BP=$GOPATH/src/github.com/gobuffalo/buffalo
RUN go version && go get -v -u github.com/markbates/deplist/deplist
RUN go version

RUN curl -sL https://deb.nodesource.com/setup_8.x | bash \
&& sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt/ `lsb_release -cs`-pgdg main" >> /etc/apt/sources.list.d/pgdg.list' \
Expand All @@ -14,19 +14,10 @@ RUN service postgresql start && \
su -c "psql -c \"ALTER USER postgres WITH PASSWORD 'postgres';\"" - postgres

RUN go get -u github.com/golang/dep/cmd/dep \
&& go get -v -u github.com/gobuffalo/makr \
&& go get -v -u github.com/gobuffalo/packr \
&& go get -v -u github.com/gobuffalo/tags \
&& go get -v -u github.com/gobuffalo/pop \
&& go get -v -u github.com/gobuffalo/x/... \
&& go get -v -u github.com/mattn/go-sqlite3 \
&& go get -v -u github.com/markbates/filetest \
&& go get -v -u github.com/markbates/grift \
&& go get -v -u github.com/markbates/inflect \
&& go get -v -u github.com/markbates/refresh \
&& go get -v -u github.com/gobuffalo/httptest \
&& go get -v -u github.com/gorilla/sessions \
&& go get -v -u golang.org/x/vgo \
&& go get -u github.com/alecthomas/gometalinter \
&& gometalinter --install

Expand All @@ -38,8 +29,7 @@ RUN npm install -g --no-progress yarn \
RUN rm -rfv $BP && mkdir -p $BP
WORKDIR $BP
COPY . .
RUN make deps && make install

RUN make ci-deps && make install

# cache yarn packages to an offline mirror so they're faster to load. hopefully.
RUN grep -v '{{' ./generators/assets/webpack/templates/package.json.tmpl > package.json \
Expand Down
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@ test:
packr
$(GO_BIN) test -tags ${TAGS} ./...

ci-test: deps
ci-deps:
$(GO_BIN) get github.com/gobuffalo/packr/packr
$(GO_BIN) get -tags ${TAGS} -t -u -v ./...

ci-test: ci-deps
docker build . --no-cache

lint:
Expand Down

0 comments on commit 93538a2

Please sign in to comment.