Comments (3)
I'm not familiar with the inner workings of gcloud compute ssh
but I assume it will need ssh
and ssh-keygen
installed in the Docker image, I am not sure these packages there. ssh
certainly not installed in the new alpine-based image we're about to publish. What error are you seeing? Do other commands work fine?
from cloud-sdk-docker.
No errors, just that it prompts me for a password unlike when I run the command directly on gcloud.
Same issue when I run from my own image https://github.com/chad-autry/wac-gce-ansible
The whole purpose there was to package an ansible install into docker, but in the end I've installed ansible to my gcloud directory (with a script imitating the ssh command, but internally using gcloud compute ssh for the auto-authentication).
from cloud-sdk-docker.
Looks like the README currently doens't show how to map your credential volume into a container.
the procedure is described in this article (specifically under Run gcloud cli without installing SDK locally
). I'll separately update the readme in this repo to describe this procedure ot map credentils over. Note, once you create a volume w/ your creds in it, please handle it w/ care!
anyway, if you've initalized gcloud already on a laptop and have creds locally, you can ssh in w/ a similar technique:
$ docker run -ti -v ~/.ssh:/root/.ssh -v ~/.config/gcloud:/root/.config/gcloud google/cloud-sdk gcloud compute ssh $USER@janus --project your_projectID --zone us-central1-a
then i'm logged in to the remote
srashid@janus:~$
LMK if this works for you (i'll close this out then but update the readme anyway)
from cloud-sdk-docker.
Related Issues (20)
- emulators firestore lost connection when cloud build run HOT 3
- GPG Error when trying to install GCloud CLI on a docker image HOT 2
- multi-arch images? HOT 9
- Zscaler support HOT 3
- Apt install of gcloud components is broken on `slim` HOT 3
- Error response from daemon: Head "https://gcr.io/v2/google.com/cloudsdktool/google-cloud-cli/manifests/latest": unauthorized: failed authentication HOT 2
- Buildx missing HOT 6
- `gke-gcloud-auth-plugin` does not honor `CLOUDSDK_CONFIG` env var HOT 1
- Image tag 433 breaks docker authentication HOT 5
- Entrypoint doesn't work in Dockerfile from version 430.0.0 HOT 2
- Update Alpine image to 3.18 HOT 1
- Pubsub shutdown time
- The Debian packages using the wrong architecture, etc in the official container HOT 1
- Alpine image missing libresolv.so.2 for kubectl HOT 1
- Upgrade Debian image to bookworm HOT 8
- Curl upgrade to include fail-with-body option HOT 3
- Installing config-connector component HOT 2
- kubectl binary contains CVE-2023-39323 security vulnerability HOT 3
- When updating cloud run jobs image, job task-timeout is reset to default value. HOT 1
- Are you planning to host the image on pkg.dev? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cloud-sdk-docker.