1

I created a python script to manage a group chat application I am writing for iOS. The script uses sockets to send a string of text (from a list), that is interpreted in my ios app to populate and array to be displayed in a uitableview. For other people to connect with it, I decided to use OpenShift, and I ran into a problem. I can run the script ok using action hooks, but I need to connect my client (ios app), to my server (script on openshift). How would I get an IP and port from openshift to connect my client to?

TL;DR: Wrote a python script to manage an iphone chat app using sockets. Uploaded it to openshift, but can't get the ip/port to connect to it.

6
  • @mbaird What would I use to get the IP? Jun 17, 2015 at 4:14
  • 1
    There are some environment variables with lot of the config, see the openshift's help
    – user3134284
    Jun 17, 2015 at 13:34
  • So would I get the ip from OPENSHIFT_PYTHON_IP and port from OPENSHIFT_PYTHON_PORT ? Also, how will I send the data to this ip from my ios app? Jun 17, 2015 at 15:25
  • 1
    You need to send data to your application using your application url (app-domain.rhcloud.com) and use port 8000 (or port 8443 for secure web sockets)
    – user2879327
    Jun 17, 2015 at 15:28

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.