I get this error
x509: certificate signed by unknown authority
when I try to put an object to Spaces using access keys in a docker container. I can get files just fine, and I can put files from my local machine (not in a docker container). I’m using the minio package from a golang app. This happens even with ssl=false. Is it looking for a cert only on puts?
Here’s what my code looks like
endpoint := "sfo3.digitaloceanspaces.com"
bucket := "mybucket"
ssl := false
client, err := minio.New(endpoint, accessKey, secKey, ssl)
if err != nil {
fmt.Println(err)
return nil
}
//this get works fine
obj, err := client.GetObject(bucket, fileName, minio.GetObjectOptions{})
if err != nil {
fmt.Println(err)
return nil
}
reader := bytes.NewReader(contents)
//this put fails
_, err = client.PutObject(bucket, "test.jpeg", reader, reader.Size(), minio.PutObjectOptions{})
if err != nil {
fmt.Println(err) //this is where I get the error
}
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi there,
There has been a similar problem reported here:
The suggested solution was to update your CA certificates as described here:
http://manpages.ubuntu.com/manpages/bionic/man8/update-ca-certificates.8.html
And also try to update your packages too just in case.
Let me know how it goes.
Best,
Bobby
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.