How-tos

How to run your apps locally and remotely in IBM Cloud Tools for Swift

Share this post:

IBM Cloud Tools for Swift (ICT) is a tool for Mac users to deploy, manage and monitor applications on Bluemix. It’s part of a larger initiative at IBM to bring Swift to the Server.

ICT Version 1.2 and later makes it much easier and quicker for users to test their apps. Users can change their client app (front-end code) to point locally or remotely. To take advantage of this feature, an app must contain a plist file with the correct configurations.

Steps for configuration:

    1. Open Finder and navigate to your app’s directory. Once there, create a ‘Configuration’ directory inside your app directory.

creatingconfigurationfolder1

    1. Open Xcode and select File -> New -> File… When the dialog opens, select ‘Resource’ under OS X. Then select ‘Property List’.

creatingpropertylist1

    1. Click ‘Next’. Rename the Property List to ‘bluemix.plist’ then place the new Property List in your newly created ‘Configuration’ directory inside your app’s directory.

addingplistfile1

    1. Click ‘Create’. Inside the newly created bluemix.plist, create three keys:’isLocal’ (boolean), ‘appRouteLocal’ (String) and ‘appRouteRemote’ (String).
      Fill in ‘appRouteLocal’ and ‘appRouteRemote’ with the Values you want them to be.

plistexampleconfig1

    1. Changing the “Connected to:” selector within ICT will toggle ‘isLocal’ to be ‘NO’ or ‘YES’. You can also change these from the ‘bluemix.plist’ file, which will be shown in the IBM for Cloud Tools dashboard.When ‘isLocal’ = YES, ‘appRouteLocal’ is used as the client target.
      approutelocalexample1
      When ‘isLocal’ = NO, ‘appRouteRemote’ is used.

 

approuteremoteexample1

 

If you haven’t already done so, download the latest version of IBM Cloud Tools for Swift. If you would like to submit feedback to our team, please complete our survey. If you have any issues with the app, submit questions on dW Answers. To learn more about Swift@IBM, visit our website.

Add Comment
No Comments

Leave a Reply

Your email address will not be published.Required fields are marked *

More Mobile Stories

Kubernetes Log Forwarding with Syslog

Logs help you troubleshoot issues with your clusters and apps. Sometimes, you might want to send logs somewhere for processing or long-term storage. On a Kubernetes cluster in the IBM Cloud Container Service, you can enable log forwarding for your cluster and choose where your logs are forwarded.

Continue reading

Keeping up-to-date with Kubernetes

Kubernetes development and adoption continues to grow at a rapid pace, and keeping current can be difficult without the right process and tools. For example, IBM Cloud Container Service launched with support for Kubernetes v1.5.6 earlier this year. Since that initial launch, the Kubernetes community provided 3 minor releases (v1.6, v1.7, and v1.8) and over 25 patch releases. By year's end there's likely to be another minor release and numerous patches. So with all this change, what's the best way to keep your cluster and apps up-to-date and secure?

Continue reading

Home automation powered by Cloud Functions, Raspberry Pi, Twilio and Watson

Over the past few years, we’ve seen a significant rise in popularity for intelligent personal assistants, such as Apple’s Siri, Amazon Alexa, and Google Assistant. Though they initially appeared to be little more than a novelty, they’ve evolved to become rather useful as a convenient interface to interact with service APIs and IoT connected devices.

Continue reading