cmd/gitmirror: remove reference to obsolete "apt-key"
The Dockerfile was using the "old" version of some
command-line incantation, this is the "new" version.
diff --git a/cmd/gitmirror/Dockerfile b/cmd/gitmirror/Dockerfile
index 2862bb3..4b73d9d 100644
--- a/cmd/gitmirror/Dockerfile
+++ b/cmd/gitmirror/Dockerfile
@@ -35,7 +35,12 @@
&& rm -rf /var/lib/apt/lists/*
# Install gcloud for auth to CSR, see https://cloud.google.com/sdk/docs/install#deb
-RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] http://packages.cloud.google.com/apt cloud-sdk main" | tee -a /etc/apt/sources.list.d/google-cloud-sdk.list && curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key --keyring /usr/share/keyrings/cloud.google.gpg add - && apt-get update -y && apt-get install google-cloud-sdk -y && rm -rf /var/lib/apt/lists/*
+RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] http://packages.cloud.google.com/apt cloud-sdk main" | \
+ tee -a /etc/apt/sources.list.d/google-cloud-sdk.list && \
+ curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | \
+ gpg --dearmor -o /usr/share/keyrings/cloud.google.gpg && \
+ apt-get update -y && apt-get install google-cloud-sdk -y && \
+ rm -rf /var/lib/apt/lists/*
# Add github.com's known_hosts entries, so git push calls later don't
# prompt, and don't need to have their strict host key checking
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +2 |
Thanks. Some minor (optional) suggestions.
RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] http://packages.cloud.google.com/apt cloud-sdk main" | \
tee -a /etc/apt/sources.list.d/google-cloud-sdk.list && \
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | \
gpg --dearmor -o /usr/share/keyrings/cloud.google.gpg && \
apt-get update -y && apt-get install google-cloud-sdk -y && \
rm -rf /var/lib/apt/lists/*Splitting this long line to one-line-per-command for readability seems good, but maybe it's worth keeping the one-command-pipe-into-another together? I don't feel strongly about it, so feel free not to change it.
Also s/http/https/ in one of the URLs and let's stay with tabs for indentation since that's used above and below (too bad we don't benefit from gofmt here).
Something like:
```suggestion
RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main" | tee -a /etc/apt/sources.list.d/google-cloud-sdk.list && \
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | gpg --dearmor -o /usr/share/keyrings/cloud.google.gpg && \
apt-get update -y && apt-get install google-cloud-sdk -y && \
rm -rf /var/lib/apt/lists/*
```
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] http://packages.cloud.google.com/apt cloud-sdk main" | \
tee -a /etc/apt/sources.list.d/google-cloud-sdk.list && \
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | \
gpg --dearmor -o /usr/share/keyrings/cloud.google.gpg && \
apt-get update -y && apt-get install google-cloud-sdk -y && \
rm -rf /var/lib/apt/lists/*Splitting this long line to one-line-per-command for readability seems good, but maybe it's worth keeping the one-command-pipe-into-another together? I don't feel strongly about it, so feel free not to change it.
Also s/http/https/ in one of the URLs and let's stay with tabs for indentation since that's used above and below (too bad we don't benefit from gofmt here).
Something like:
```suggestion
RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main" | tee -a /etc/apt/sources.list.d/google-cloud-sdk.list && \
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | gpg --dearmor -o /usr/share/keyrings/cloud.google.gpg && \
apt-get update -y && apt-get install google-cloud-sdk -y && \
rm -rf /var/lib/apt/lists/*
```
I added the missing "s" to http and then re-deployed to be sure that it still worked. Should be tabs for whitespace, did not reflow the line because I could not easily read the other one.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +2 |
Thanks.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |