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

chore: refactor docker images #397

Merged
merged 1 commit into from
Oct 15, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
lint:
<<: *golang_workspace
docker:
- image: bertychat/linter:latest
- image: bertychat/linter:v2
steps:
- checkout
- restore_cache:
Expand Down Expand Up @@ -201,7 +201,7 @@ jobs:
client.rn.android:
working_directory: ~/go/src/berty.tech/client/react-native/mobile/android
docker:
- image: bertychat/android-ci:latest
- image: bertychat/android-ci:v2
steps:
- checkout:
path: ~/go/src/berty.tech/
Expand Down
15 changes: 0 additions & 15 deletions .circleci/docker/Makefile

This file was deleted.

7 changes: 7 additions & 0 deletions build/docker/android-ci/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
IMAGE ?= bertychat/android-ci:v2

build:
docker build --pull -t $(IMAGE) .

release: build
docker push $(IMAGE)
File renamed without changes.
7 changes: 7 additions & 0 deletions build/docker/linter/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
IMAGE ?= bertychat/linter:v2

build:
docker build --pull -t $(IMAGE) .

release: build
docker push $(IMAGE)
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
FROM moul/protoc-gen-gotemplate as pgg
FROM moul/protoc-gen-gotemplate:latest as pgg

FROM golang:1.11-alpine as builder

RUN apk --update add make git go rsync libc-dev openssh docker
RUN apk --no-cache add make git go rsync libc-dev openssh docker

RUN go get -u -v \
github.com/gogo/protobuf/proto \
Expand All @@ -20,7 +20,7 @@ RUN cd /go/src/github.com/99designs/gqlgen && git checkout v0.6.0 && go inst
RUN rm -f /go/bin/web-editor

FROM golang:1.11-alpine
RUN apk --update add git make protobuf gcc libc-dev && mkdir -p /.cache/go-build && chmod -R 777 /.cache
RUN apk --no-cache add git make protobuf gcc libc-dev && mkdir -p /.cache/go-build && chmod -R 777 /.cache
COPY --from=pgg /go/bin/* /go/bin/
COPY --from=builder /go/bin/* /go/bin/
COPY --from=pgg /protobuf /protobuf
Expand Down
7 changes: 7 additions & 0 deletions build/docker/protoc/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
IMAGE ?= bertychat/protoc:v3

build:
docker build --pull -t $(IMAGE) .

release: build
docker push $(IMAGE)
2 changes: 1 addition & 1 deletion client/react-native/gomobile/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ PWD := $(shell pwd)
CORE_PACKAGE := $(PWD)/../../../core
CORE_SOURCES := $(shell find $(CORE_PACKAGE) -type f -name "*.go") \
$(shell find . -type f -name "*.go")
BUILD_PATCH_PATH := $(PWD)/../../../.circleci/docker
BUILD_PATCH_PATH := $(PWD)/../../../build/docker/android-ci

GOPATH ?= $(HOME)/go

Expand Down