Access Application Args
Provides a Cloudflare Access Application resource. Access Applications are used to restrict access to a whole application using an authorisation gateway managed by Cloudflare.
It's required that an
account_idorzone_idis provided and in most cases using either is fine. However, if you're using a scoped access token, you must provide the argument that matches the token's scope. For example, an access token that is scoped to the "example.com" zone needs to use thezone_idargument.
Example Usage
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.cloudflare.AccessApplication;
import com.pulumi.cloudflare.AccessApplicationArgs;
import com.pulumi.cloudflare.inputs.AccessApplicationCorsHeaderArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var stagingApp = new AccessApplication("stagingApp", AccessApplicationArgs.builder()
.corsHeaders(AccessApplicationCorsHeaderArgs.builder()
.allowCredentials(true)
.allowedMethods(
"GET",
"POST",
"OPTIONS")
.allowedOrigins("https://example.com")
.maxAge(10)
.build())
.domain("staging.example.com")
.name("staging application")
.sessionDuration("24h")
.type("self_hosted")
.zoneId("0da42c8d2132a9ddaf714f9e7c920711")
.build());
}
}Import
$ pulumi import cloudflare:index/accessApplication:AccessApplication example <account_id>/<application_id>Constructors
Properties
The identity providers selected for the application.
Option to show/hide applications in App Launcher. Defaults to true.
Option to skip identity provider selection if only one is configured in allowed_idps. Defaults to false.
CORS configuration for the Access Application. See below for reference structure.
Option that returns a custom error message when a user is denied access to the application.
Option that redirects to a custom URL when a user is denied access to the application.
Option to provide increased security against compromised authorization tokens and CSRF attacks by requiring an additional "binding" cookie on requests. Defaults to false.
Option to add the HttpOnly cookie flag to access tokens.
SaaS configuration for the Access Application.
Defines the same-site cookie setting for access tokens. Available values: none, lax, strict.
Option to return a 401 status code in service authentication rules on failed requests. Defaults to false.
How often a user will be forced to re-authorise. Must be in the format 48h or 2h45m. Defaults to 24h.
Option to skip the authorization interstitial when using the CLI. Defaults to false.