Open joaofnfernandes opened 8 years ago
@joaofnfernandes
It is the docker-cloud
binary that reads the the environment variable. If you run the cli using the container, the envvar you exposed in the shell will not be passed into the container unless you use -e
.
You can use alias
mentioned in the README:
alias docker-cloud="docker run -it -e DOCKERCLOUD_USER=username -e DOCKERCLOUD_PASS=password --rm dockercloud/cli"
Ups... My first description was wrong. I meant to say that I tried
export DOCKERCLOUD_USER=<username>
export DOCKERCLOUD_PASS=<password>
docker run -it -e DOCKERCLOUD_USER -e DOCKERCLOUD_PASS dockercloud/cli
In this case the variables are passed to the container (if I do a docker exec
I can see them there), but the docker-cloud
binary didn't seem to be picking them,
The docs say that to authenticate you need to export the environment variables:
But if you export those variables and then
docker run -it dockercloud/cli
, you're not authenticated. But running the image with this command, seems to work:I've also found this forum post with a similar problem.