Skip to content
This repository was archived by the owner on Oct 11, 2024. It is now read-only.

Comments

Cache go mod download#1325

Merged
gdbelvin merged 3 commits intogoogle:masterfrom
gdbelvin:cacheDocker
Jul 18, 2019
Merged

Cache go mod download#1325
gdbelvin merged 3 commits intogoogle:masterfrom
gdbelvin:cacheDocker

Conversation

@gdbelvin
Copy link
Contributor

No description provided.

@gdbelvin gdbelvin requested a review from a team as a code owner July 18, 2019 12:56
@gdbelvin gdbelvin requested a review from RJPercival July 18, 2019 12:57
@@ -1,9 +1,13 @@
FROM golang:1.12 as build

WORKDIR /go/src/github.com/google/keytransparency
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be neat if these all shared the same build stage, is that possible?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How do I do that?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or what would be the value in doing that?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was thinking that if there were something like:

FROM ... as base
...
go mod download
COPY ...

which was then shared by all the job-specific Dockerfiles, e.g.:


FROM base as build:
go get .../${thing}

FROM distroless/...
COPY --from=build ...

Then you'd save having to rebuild the same base image/re-fetching the same modules etc. repeatedly.

@codecov
Copy link

codecov bot commented Jul 18, 2019

Codecov Report

Merging #1325 into master will increase coverage by 0.02%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1325      +/-   ##
==========================================
+ Coverage   30.26%   30.29%   +0.02%     
==========================================
  Files          48       48              
  Lines        3869     3869              
==========================================
+ Hits         1171     1172       +1     
+ Misses       2517     2516       -1     
  Partials      181      181
Impacted Files Coverage Δ
core/client/client.go 28.94% <0%> (+0.65%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update de5b12d...6e36c75. Read the comment docs.

@RJPercival RJPercival assigned AlCutter and unassigned RJPercival Jul 18, 2019
* master:
  Extract log tracking into separate package  (google#1317)
@gdbelvin gdbelvin merged commit a34e14b into google:master Jul 18, 2019
gdbelvin added a commit to gdbelvin/keytransparency that referenced this pull request Jul 18, 2019
* master:
  Cache go mod download (google#1325)
  Extract log tracking into separate package  (google#1317)
@gdbelvin gdbelvin deleted the cacheDocker branch July 18, 2019 16:40
gdbelvin added a commit to gdbelvin/keytransparency that referenced this pull request Jul 18, 2019
* master:
  Cache go mod download (google#1325)
  Extract log tracking into separate package  (google#1317)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants