Reader small image

You're reading from  Swift Cookbook - Second Edition

Product typeBook
Published inFeb 2021
Reading LevelIntermediate
PublisherPackt
ISBN-139781839211195
Edition2nd Edition
Languages
Tools
Right arrow
Authors (2):
Keith Moon
Keith Moon
author image
Keith Moon

Keith Moon is an award-winning iOS developer, author and speaker based in London. He has worked with some of the biggest companies in the world to create engaging and personal mobile experiences. Keith has been developing in Swift since its release, working on projects both fully Swift, and mixed Swift and Objective-C. Keith has been invited to speak about Swift development in conferences from Moscow to Minsk and London.
Read more about Keith Moon

Chris Barker
Chris Barker
author image
Chris Barker

Chris Barker is an iOS developer and tech lead for fashion retailer N Brown (JD Williams, SimplyBe, Jacamo), where he heads up the iOS team. Chris started his career developing .NET applications for online retailer dabs (now BT Shop) before he made his move into mobile app development with digital agency Openshadow (now MyStudioFactory Paris). There, he worked on mobile apps for clients such as Louis Vuitton, L'Oréal Paris, and the Paris Metro. Chris often attends and speaks at local iOS developer meetups and conferences such as NSManchester, Malaga Mobile, and CodeMobile.
Read more about Chris Barker

View More author details
Right arrow

Hosting your Vapor app on Heroku

In the previous recipes in this chapter, we created a REST API that stores and retrieves information from a Postgres database. We have our Vapor web server running on our local machine and can interact with it over HTTP requests; however, unless you plan on making your machine available to the public internet, this is of limited use, and we need to find somewhere to host our data and REST interface.

At the time of writing, Swift's support on hosting services is the exception rather than the norm; however, support is growing. Heroku is a popular hosting service that provides dynamic scaling of resources and a really simple deployment mechanism. It also has support for Swift and Postgres, so in this recipe, we will deploy our REST API to Heroku.

Getting started

Heroku provides simple and scalable infrastructure for your server-side projects. Once deployed, instances of your app are called Dymos, and additional Dymos can be started to cope with increased...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Swift Cookbook - Second Edition
Published in: Feb 2021Publisher: PacktISBN-13: 9781839211195

Authors (2)

author image
Keith Moon

Keith Moon is an award-winning iOS developer, author and speaker based in London. He has worked with some of the biggest companies in the world to create engaging and personal mobile experiences. Keith has been developing in Swift since its release, working on projects both fully Swift, and mixed Swift and Objective-C. Keith has been invited to speak about Swift development in conferences from Moscow to Minsk and London.
Read more about Keith Moon

author image
Chris Barker

Chris Barker is an iOS developer and tech lead for fashion retailer N Brown (JD Williams, SimplyBe, Jacamo), where he heads up the iOS team. Chris started his career developing .NET applications for online retailer dabs (now BT Shop) before he made his move into mobile app development with digital agency Openshadow (now MyStudioFactory Paris). There, he worked on mobile apps for clients such as Louis Vuitton, L'Oréal Paris, and the Paris Metro. Chris often attends and speaks at local iOS developer meetups and conferences such as NSManchester, Malaga Mobile, and CodeMobile.
Read more about Chris Barker