How-tos

Submitting a Project to IBM Cloud Tools for Swift

Share this post:

Disclaimer: IBM Cloud Tools for Swift (ICT) is no longer supported. Check out IBM Cloud App Service to take advantage of the same features of ICT in a more comprehensive experience for building Cloud Native applications in any programming language.

IBM Cloud Tools for Swift (ICT) is a Mac application for deploying, managing, and monitoring end-to-end applications on IBM Bluemix. It is part of a larger IBM initiative to bring Swift to the Server.

ICT now offers the exciting opportunity for any team to show off its technology or project to new users! You can now submit a project to be showcased in the “Featured Projects” screen (see below).

All you need are the following three components prior to submission:

  1. Github repository: Contains the source code that ICT will clone and deploy to Bluemix
  2. Links to project images: Images must be created and hosted by project owners for ICT to display
  3. Project descriptions: Informs potential users of the project they’re about to create

In this blog post, we will walk through the submission process by using BluePic as an example project to be featured on ICT.

Confirm project’s file structure follows ICT conventions

The project will need to follow the following file structure conventions and it must be a public GitHub repository:

root/
  |-- manifest.yml
  |-- {Project_Name}-Server/
  |-- {Project_Name}-iOS/
         |-- {Project_Name}/
                  |-- Configuration/
                           |-- Info.plist
                           |-- bluemix.plist
         |-- {Project_Name}.xcodeproj/
         |-- {Project_Name}.xcworkspace/
  |-- Cloud-Scripts/

  1. manifest.yml file at the root of repository. This file is used to deploy the project to Bluemix. See file documentation. Include the declared-services field in the manifest if the project uses any Bluemix services. Review the “Repository considerations for the button” section of this document.
  2. {Project_Name}-Server folder at root of repository. This folder is what gets deployed to Bluemix. If the server uses the Swift Runtime, ICT will use the Package.swift file to generate a xcode project.
  3. {Project_Name}-iOS folder at root of repository, required only if the project includes an iOS application. The iOS application will interact with the deployed application on Bluemix via a bluemix.plist file located in the {Project_Name}-iOS/{Project_Name}/Configuration folder. Include either a {Project_Name}.xcodeproj or {Project_Name}.xcworkspace file in this folder.
  4. Cloud-Scripts folder at root of repository, required only if the project has shell scripts to initialize the created Bluemix services. A folder for each Bluemix service to initialize is required within this folder. Folder name should be the same as the service label. A populator.sh script is needed in each folder. ICT will execute this script with that service’s Bluemix credentials exported.

Notice that the Project_Name must be the same as the repository’s name. Your repository’s file structure should look very similar to BluePic’s. Below you’ll find a BluePic GitHub repository with relevant folders/files annotated:

Test your project setup

You can easily test whether your project will work properly within ICT by using the Create a Sample Project from GitHub Repo feature. This will clone and deploy the project to Bluemix. Follow these steps to validate that your project will work:

  1. Create a sample project from your project’s GitHub URL.
  2. Verify Local Server Repository card (Figure 4). If a Package.swift file was provided, this will be represented by either a .xcodeproj or xcodeproj file. A cloud_config.json file should exist at the root of {Project_Name}-Server folder. ICT should have populated this file with the credentials of any created Bluemix Service.
  3. Verify Client App card. If your submission had a client app, this will be represented by either a .xcodeproj or .xcworkspace file. A bluemix.plist file should be at the root of {Project_Name}-iOS/{Project_Name}/Configuration folder. Here’s a blog post that goes into detail on how ICT interacts with this file.

Submitting your Project

Fill out the form online. The link can also be found through Submit a Featured Project option within ICT.

Here’s an example of how BluePic would fill out certain parts of the form:

  • Project title: BluePic
  • Project thumbnail: Displayed in Featured Projects screen to represent project
    • Displayed on Featured Projects screen to represent project
    • Either an image of application running on iPhone or project logo
    • 880 x 580 pixels

Here’s an example of a BluePic project thumbnail in the Featured Projects screen:

 
  • Main application screenshot: Displayed to users throughout the project creation screens
    • Image will be shown to users as they are creating the project
    • Should be a larger version of the thumbnail image
    • 1040 x 1336 pixels

Here’s an example of BluePic’s main application screenshot:

 
  • Application Screenshots: Displayed in Project Overview screen so users can see the actual screenshots of the application they will be creating
    • 1 to 5 screenshots
    • Displayed in Project Overview screen
    • 1920 x 1160 pixels

Here’s an example of the Project Overview screen:

 
  • Link to GitHub repository: https://github.com/IBM-Swift/BluePic
  • One-line overview of the project: BluePic is a sample photo sharing application.
  • Short description of the technologies used or showcased by the project: This sample includes an iOS 10 client app and a Kitura-based server app, all written in Swift.
  • Local Development Notes: Description of the components users will have after ICT clones the project. What will/won’t the user be able to do? Please note anything a user needs to set up their local development environment.Cloning the BluePic project files locally will allow you to work on the iOS application and the Kitura back end locally with Xcode. You should select the executable scheme for the server Xcode project (since Xcode defaults to a scheme of the same name, which cannot be run). Click the Run button to execute.
  • Local development requirements: Links to anything the user might need to download and install for local development
  • Local Requirement Name: Xcode 8
  • Link to Requirement: https://developer.apple.com/xcode/
  • Please add your step-by-step instructions: Try to keep these instructions specific to IBM Cloud Tools for Swift. If the user follows these instructions, by the end they should have the working featured project.Click the “View on GitHub” button above to view full instructions for setting up the iOS client and connected services. Estimated deployment time: 20 minutes.

After the project is submitted

Once you submit the form, our team will immediately get to work reviewing your project. If we have any questions, we will reach out to you. Once we test and approve your app, we will add it as a featured project. This will take approximately two weeks, and we will notify you with the date you will see your app in the tool.

Ask on dWAnswers if you have any questions about this process.

Project recommendations

  1. Please follow your company’s branding policy, if part of one.
  2. Refrain from making changes that might break your project within ICT. We suggest submitting a stable fork of your repository. If we notice that a featured project no longer works within ICT, we will remove it.
More Open Source stories

Twilio expands the number of services on IBM Cloud

Twilio is very happy to announce our expanded partnership with IBM, bringing five new custom integrations to IBM Cloud. With Twilio and IBM, you’ll be able to build communications into your Web app without worrying about provisioning and maintaining servers.

Continue reading

Getting started with TradeIt’s SDK and API

By integrating TradeIt’s core products - TradingTicket and PortfolioView - developers can bring portfolio management and order management tools to their end users. RIA and Wealth Management platforms that integrate our SDK or standardized API have higher engagement and a simplified workflow to manage across a clients portfolio and have the ability to place orders seamlessly through the same safe, secure API connections to the underlying broker. TradeIt understood that consumers were increasingly engaged on apps and social networks for the business of their lives. TradeIt brings the top Financial Institutions’ customer journey - account opening, account management and securities trading - to the apps where the action happens in a safe, secure and compliant way.

Continue reading

Cloud Functions: Easy Database Setup the Serverless Way

A tutorial I wrote, featuring a database-backed Slack chatbot, is now live. It uses Db2 as database system to store event data. The client accessing the database is written in Node.js and is implement with IBM Cloud Functions in a serverless way. During the development of that tutorial I faced the question on how to perform the database setup. Should I guide users through the user interface to create a table and insert data? Should they install a Db2 client and execute a script locally? I solved the problem in a serverless fashion. Here are the details.

Continue reading