Vapor Documentation Beta

Class Serve​Command

public final class ServeCommand: Command

Boots the application's server. Listens for SIGINT and SIGTERM for graceful shutdown.

$ swift run Run serve
Server starting on http://localhost:8080
%3 ServeCommand ServeCommand Command Command ServeCommand->Command

Nested Types

ServeCommand.Signature
ServeCommand.Error

Errors that may be thrown when serving a server

Conforms To

Command

Properties

signature

let signature

See Command.

help

var help: String

See Command.

Methods

run(using:​signature:​)

public func run(using context: CommandContext, signature: Signature) throws

See Command.