pub async fn setup(
rocket: Rocket<Build>,
config: OIDCConfig,
) -> Result<Rocket<Build>, Box<dyn Error>>Expand description
Initializes the Rocket application with OpenID Connect authentication support.
This function:
- Loads OIDC configuration from the given
config. - Calls
from_provider_oidc_configto build the authentication state. - Registers authentication-related routes under the
/authpath. - Attaches the authentication state as managed state in Rocket.
Returns the updated Rocket instance, or an error if the setup failed.