Simple Hello World Kitura Application (Server Side) embedded in an iOS app (Client Side). The app demonstrates starting and stopping Kitura server, and presents Kitura log on the screen.
- https://developer.ibm.com/swift/2017/03/13/kitura-ios/
- https://developer.ibm.com/swift/2017/12/08/kitura-ios-part2/
(Last tested on macOS Mojave 10.14 and Xcode 10.1)
- Setup (run in a terminal). The following commands install Xcode command line tools, Ruby Xcodeproj gem, download curl 7.43.0 source code and compile it. You may want to download and compile some other version of curl or to compile it using some other script, for example https://github.com/gcesarmza/curl-android-ios.
xcode-select --install
sudo gem install xcodeproj
git clone https://github.com/IBM-Swift/Kitura-HelloWorld-iOS.git
cd Kitura-HelloWorld-iOS
make Builder/Makefile
curl -O https://curl.haxx.se/download/curl-7.43.0.tar.bz2
bzip2 -d curl-7.43.0.tar.bz2; tar xopf curl-7.43.0.tar; rm -r curl-7.43.0.tar
bash ./Builder/Scripts/buildCurlStaticLibrary.sh curl-7.43.0
Troubleshooting on Mojave: if the last command above fails, follow the instructions in curl/curl#3189 (comment).
- The following command will fetch the submodules, update them, generate an Xcode project for the Server Side part and generate an Xcode workspace for the End-to-End project.
For 64Bit (example, iPhone 5s or newer, iPad Air or newer, iPad Mini 2 or newer, iPad Pro or newer)
make openXcode
For 32Bit (example, iPhone 5, 5c, iPad 4)
make openXcode32
- Open
EndToEnd.xcworkspace
- Change scheme to "ClientSide"
- Load on iPhone or iPhone simulator
- On the running app, turn on the toggle switch above the QR code
- On another device, connect to the listed URL
git pull
to get the latest version of Kitura- Remove the
Builder
directory - run
make openXcode
ormake openXcode32
Run make test