Caps-Server/Sources/App/configure.swift

18 lines
483 B
Swift
Executable File

import Vapor
/// Called before your application initializes.
///
/// [Learn More ](https://docs.vapor.codes/3.0/getting-started/structure/#configureswift)
public func configure(
_ config: inout Config,
_ env: inout Environment,
_ services: inout Services
) throws {
// Register routes to the router
let router = EngineRouter.default()
try routes(router)
services.register(router, as: Router.self)
// Configure the rest of your application here
}