0

I created IBM cloud object storage and a bucket. When I try to list the buckets in the storage it works but when trying to read or write from bucket I am getting access denied.

Ravithejs-MacBook-Pro:~$ ibmcloud cos put-object --bucket hog-cli-bucket-name --key firstOne --body /Downloads/apikey.json
FAILED
Access to your IBM Cloud account was denied. Log in again by typing ibmcloud login --sso.

I tried logging in with apikey and sso but running into same issue again

javaMan
  • 6,352
  • 20
  • 67
  • 94

2 Answers2

1

Try just apikey

ibmcloud login --apikey <replace with your api key>

Jeff Sloyer
  • 4,899
  • 1
  • 24
  • 48
lifemikey
  • 86
  • 2
0

Check the permissions for your username.

  ibmcloud iam user-policies <user-name>

You should have Manager permission. You can check the bucket permissions as listed in the documentation in this link

Vidyasagar Machupalli
  • 2,737
  • 1
  • 19
  • 29