Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DefaultMetadataServiceVersion needs to be updated (--vpc-cri is broken) #327

Open
l2fprod opened this issue Jun 30, 2022 · 2 comments
Open
Labels

Comments

@l2fprod
Copy link
Member

l2fprod commented Jun 30, 2022

with latest CLI

IBMCLOUD_TRACE=true ibmcloud login --vpc-cri -r us-south
API endpoint: https://cloud.ibm.com/
Authenticating...

REQUEST: [2022-06-30T14:28:30Z]
PUT /instance_identity/v1/token?version=2021-09-30 HTTP/1.1
Host: 169.254.169.254
Accept: application/json
Accept-Language: en-US
Accept-Language: en
Content-Type: application/json
Metadata-Flavor: ibm
User-Agent: IBM Cloud CLI 2.8.0 / linux

{"expires_in": 300}

RESPONSE: [2022-06-30T14:28:30Z] Elapsed: 38ms
HTTP/1.1 400 Bad Request
Content-Length: 205
Content-Type: application/json; charset=utf-8
Date: Thu, 30 Jun 2022 14:28:30 GMT
X-Request-Id: 182e21b1-9ce1-406b-bf1f-e29a61d7b898

{"errors":[{"code":"invalid_version_range","message":"The `version` value cannot be before `2022-03-01`.","target":{"name":"2021-09-30","type":"parameter"}}],"trace":"182e21b1-9ce1-406b-bf1f-e29a61d7b898"}
Error response from server. Status code: 400; message: {"errors":[{"code":"invalid_version_range","message":"The `version` value cannot be before `2022-03-01`.","target":{"name":"2021-09-30","type":"parameter"}}],"trace":"182e21b1-9ce1-406b-bf1f-e29a61d7b898"}

API endpoint:   https://cloud.ibm.com/
Region:
Not logged in.
FAILED
Unable to authenticate.

Version should be updated in

DefaultMetadataServiceVersion = "2021-09-30"
following https://cloud.ibm.com/apidocs/vpc-metadata#versioning

@l2fprod l2fprod added the bug label Jun 30, 2022
@fode-ibm
Copy link

Analysis ^ appears to be correct. CLI cannot specify any version of VPC Metadata API earlier than the GA date, per API requirement. Initial version is 2022-03-01. I recommend change to,

DefaultMetadataServiceVersion = "2022-03-01"

@steveclay
Copy link
Collaborator

This is being addressed. For the time-being, users can login using the API https://cloud.ibm.com/apidocs/vpc-metadata#create-iam-token

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants