Skip to content

Instance Method

start()

When called, this will execute the startup command provided through an argument. If no startup command is provided, the default is used. Under normal circumstances, this will start running Vapor’s webserver.
func start() throws

Discussion

If you start Vapor through this method, you’ll need to prevent your Swift Executable from closing yourself. If you want to run your Application indefinitely, or until your code shuts the application down, use run() instead.

Warning

You should probably be using startup() instead of this method.