Re: Bosh newbie with log-in issue


Dmitriy Kalinin
 

there is `bosh envs` command to list what environments were aliased (
http://bosh.io/docs/cli-v2.html#env-mgmt).

On Fri, Jun 30, 2017 at 1:10 PM, Paul Sorensen <paul.sorensen(a)magnet.com>
wrote:

You are exactly right not using the –e did the trick and has gotten me to
the next issue – thanks for your help.



What command should I use to find out what I should be using for the –e ?



*From: *Dmitriy Kalinin <dkalinin(a)pivotal.io>
*Reply-To: *"Discussions about the Cloud Foundry BOSH project." <
cf-bosh(a)lists.cloudfoundry.org>
*Date: *Friday, June 30, 2017 at 12:17 PM
*To: *"Discussions about the Cloud Foundry BOSH project." <
cf-bosh(a)lists.cloudfoundry.org>
*Subject: *[cf-bosh] Re: Bosh newbie with log-in issue



After running `export BOSH_ENVIRONMENT=$(bbl director-address)` there is
no need to specify -e on subsequent commands. My guess is that whatever
`bbl director-address` returns is different from what you are typing in -e,
hence cli considers them different destinations. Try running env and deploy
commands without -e.



On Fri, Jun 30, 2017 at 11:10 AM, Paul Sorensen <paul.sorensen(a)magnet.com>
wrote:

I’m new to bosh, and trying to get an AWS Cloud Foundry set up going. I’m
trying to get step 2 working from the “cf-deployment” docs here:
https://github.com/cloudfoundry/cf-deployment#readiness



I start by logging into bosh director:



$ export BOSH_ENVIRONMENT=$(bbl director-address)

$ bosh log-in

Using environment 'https://X.X.X.X:25555' as client 'admin'



Logged in to 'https://X.X.X.X:25555'



Succeeded



$ export SYSTEM_DOMAIN=X

$ bosh -e X.X.X.X -d cf deploy cf-deployment/cf-deployment.yml
--vars-store env-repo/deployment-vars.yml -v system_domain=$SYSTEM_DOMAIN
-o cf-deployment/operations/aws.yml -o cf-deployment/operations/
change-logging-port-for-aws-elb.yml -o cf-deployment/operations/
disable-router-tls-termination.yml -o cf-deployment/operations/
scale-to-one-az.yml

Using environment 'X.X.X.X' as anonymous user



Using deployment 'cf'



Processing release 'binary-buildpack/1.0.13':

Finding releases:

Director responded with non-successful status code '401' response 'Not
authorized: '/releases'

'



Exit code 1

So, I’m logged in but not authorized? Then I run this:



$ bosh -e X.X.X.X env

Using environment 'X.X.X.X' as anonymous user



Name bosh-bbl-env-saimaa-2017-06-21t21-02z

UUID 2e6d1363-819f-45da-b82e-[snip]

Version 261.4.0 (00000000)

CPI aws_cpi

Features compiled_package_cache: disabled

config_server: disabled

dns: disabled

snapshots: disabled

User (not logged in)



Succeeded



And see that indeed, it says I’m not logged in – but I ran the “bosh
log-in” command. Is there another type of log-in?

This e-mail and any attached files are intended solely for the use of the
individual or entity to which this mail is addressed and may contain
information that is privileged, confidential and exempt from disclosure
under applicable law. Any use, disclosure, copying or distribution of this
e-mail or the attached files by anyone other than the intended recipient is
strictly prohibited. If you have received this e-mail in error, please
notify the sender by reply e-mail or collect call to (650) 388-4111 and
delete this e-mail and attached files from your system. Thank you.


This e-mail and any attached files are intended solely for the use of the
individual or entity to which this mail is addressed and may contain
information that is privileged, confidential and exempt from disclosure
under applicable law. Any use, disclosure, copying or distribution of this
e-mail or the attached files by anyone other than the intended recipient is
strictly prohibited. If you have received this e-mail in error, please
notify the sender by reply e-mail or collect call to (650) 388-4111 and
delete this e-mail and attached files from your system. Thank you.

Join cf-bosh@lists.cloudfoundry.org to automatically receive all group messages.