Open lorddaedra opened 6 years ago
@VladRassokhin
Hi, Vlad!
What do you think about it? it should be easy to maintain because of no version updates required, it will always install latest available version.
Another solution - use docker in docker (but it require to use --privileged flag) or mount docker.sock inside Agent. Next use https://github.com/GoogleCloudPlatform/cloud-sdk-docker/blob/master/Dockerfile (https://hub.docker.com/r/google/cloud-sdk/), but this solution can't be the best for security reasons...
I'm trying to keep agent image as tiny as possible (but failing sometimes) Tried your snippet with on teamcity-agent, got next size results
docker history gcloud-agent
IMAGE CREATED CREATED BY SIZE COMMENT
ee7e6fab578a 4 seconds ago /bin/sh -c echo "Installing Google Cloud S... 164MB "Add gloud"
5ae0b299f785 12 days ago /bin/sh -c #(nop) COPY file:fa3ff1c6bbbc42... 111B "Last in teamcity-agent:latest"
I'd say adding 164Mb is quite too expensive. I'd suggest to use docker-in-docker approach or building new image on top of jetbrains/teamcity-agent
Is will allow to use gsutil tools to sync local static folder with google cloud storage bucket (like s3 equivalent)
From: https://cloud.google.com/storage/docs/gsutil_install#deb