Quantcast
Channel: Active questions tagged amazon-ec2 - Stack Overflow
Viewing all articles
Browse latest Browse all 29248

Xcode 11 Error connecting with Parse to Amazon Web Service

$
0
0

I am trying to connect to my AWS server, but when I try to save an object there, Xcode cannot reach and trow me this error:

Optional(Error Domain=Parse Code=0 "unauthorized" UserInfo={error=unauthorized, NSLocalizedDescription=unauthorized, temporary=0})

Here's my code on appDelegate:

Parse.enableLocalDatastore()    let parseConfiguration = ParseClientConfiguration(block: { (ParseMutableClientConfiguration) -> Void in        ParseMutableClientConfiguration.applicationId = "*******"        ParseMutableClientConfiguration.clientKey = "****************"        ParseMutableClientConfiguration.server = "http://ec2-3-22-186-169.us-east-2.compute.amazonaws.com/parse"    })    Parse.initialize(with: parseConfiguration)    testParseSave()    return true}func testParseSave() {    let testObject = PFObject(className: "MyTestObject")    testObject["foo"] = "bar"    testObject.saveInBackground { (success, error) -> Void in        if success {            print("El objeto se ha guardado en Parse correctamente.")        } else {            if error != nil {                print("is NOT nil:")                print (error as Any)            } else {                print("IS nil:")                print ("Error")            }        }    }}

Thanks in advance!


Viewing all articles
Browse latest Browse all 29248

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>