All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.cloudsnorkel.cdk.github.runners.LambdaAccess Maven / Gradle / Ivy

package com.cloudsnorkel.cdk.github.runners;

/**
 * (experimental) Access configuration options for Lambda functions like setup and webhook function.
 * 

* Use this to limit access to these functions. */ @javax.annotation.Generated(value = "jsii-pacmak/1.80.0 (build bce6a1d)", date = "2023-05-15T23:33:11.588Z") @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) @software.amazon.jsii.Jsii(module = com.cloudsnorkel.cdk.github.runners.$Module.class, fqn = "@cloudsnorkel/cdk-github-runners.LambdaAccess") public abstract class LambdaAccess extends software.amazon.jsii.JsiiObject { protected LambdaAccess(final software.amazon.jsii.JsiiObjectRef objRef) { super(objRef); } protected LambdaAccess(final software.amazon.jsii.JsiiObject.InitializationMode initializationMode) { super(initializationMode); } /** */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) protected LambdaAccess() { super(software.amazon.jsii.JsiiObject.InitializationMode.JSII); software.amazon.jsii.JsiiEngine.getInstance().createNewObject(this); } /** * (experimental) Provide access using API Gateway. *

* This is the most secure option, but requires additional configuration. It allows you to limit access to specific IP addresses and even to a specific VPC. *

* To limit access to GitHub.com use: *

*

     * LambdaAccess.apiGateway({
     *   allowedIps: LambdaAccess.githubWebhookIps(),
     * });
     * 
*

* Alternatively, get and manually update the list manually with: *

*

     * curl https://api.github.com/meta | jq .hooks
     * 
*

* @param props */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public static @org.jetbrains.annotations.NotNull com.cloudsnorkel.cdk.github.runners.LambdaAccess apiGateway(final @org.jetbrains.annotations.Nullable com.cloudsnorkel.cdk.github.runners.ApiGatewayAccessProps props) { return software.amazon.jsii.JsiiObject.jsiiStaticCall(com.cloudsnorkel.cdk.github.runners.LambdaAccess.class, "apiGateway", software.amazon.jsii.NativeType.forClass(com.cloudsnorkel.cdk.github.runners.LambdaAccess.class), new Object[] { props }); } /** * (experimental) Provide access using API Gateway. *

* This is the most secure option, but requires additional configuration. It allows you to limit access to specific IP addresses and even to a specific VPC. *

* To limit access to GitHub.com use: *

*

     * LambdaAccess.apiGateway({
     *   allowedIps: LambdaAccess.githubWebhookIps(),
     * });
     * 
*

* Alternatively, get and manually update the list manually with: *

*

     * curl https://api.github.com/meta | jq .hooks
     * 
*/ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public static @org.jetbrains.annotations.NotNull com.cloudsnorkel.cdk.github.runners.LambdaAccess apiGateway() { return software.amazon.jsii.JsiiObject.jsiiStaticCall(com.cloudsnorkel.cdk.github.runners.LambdaAccess.class, "apiGateway", software.amazon.jsii.NativeType.forClass(com.cloudsnorkel.cdk.github.runners.LambdaAccess.class)); } /** * (experimental) Downloads the list of IP addresses used by GitHub.com for webhooks. *

* Note that downloading dynamic data during deployment is not recommended in CDK. This is a workaround for the lack of a better solution. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public static @org.jetbrains.annotations.NotNull java.util.List githubWebhookIps() { return java.util.Collections.unmodifiableList(software.amazon.jsii.JsiiObject.jsiiStaticCall(com.cloudsnorkel.cdk.github.runners.LambdaAccess.class, "githubWebhookIps", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class)))); } /** * (experimental) Provide access using Lambda URL. *

* This is the default and simplest option. It puts no limits on the requester, but the Lambda functions themselves authenticate every request. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public static @org.jetbrains.annotations.NotNull com.cloudsnorkel.cdk.github.runners.LambdaAccess lambdaUrl() { return software.amazon.jsii.JsiiObject.jsiiStaticCall(com.cloudsnorkel.cdk.github.runners.LambdaAccess.class, "lambdaUrl", software.amazon.jsii.NativeType.forClass(com.cloudsnorkel.cdk.github.runners.LambdaAccess.class)); } /** * (experimental) Disables access to the configured Lambda function. *

* This is useful for the setup function after setup is done. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public static @org.jetbrains.annotations.NotNull com.cloudsnorkel.cdk.github.runners.LambdaAccess noAccess() { return software.amazon.jsii.JsiiObject.jsiiStaticCall(com.cloudsnorkel.cdk.github.runners.LambdaAccess.class, "noAccess", software.amazon.jsii.NativeType.forClass(com.cloudsnorkel.cdk.github.runners.LambdaAccess.class)); } /** * A proxy class which represents a concrete javascript instance of this type. */ @software.amazon.jsii.Internal private static final class Jsii$Proxy extends com.cloudsnorkel.cdk.github.runners.LambdaAccess { protected Jsii$Proxy(final software.amazon.jsii.JsiiObjectRef objRef) { super(objRef); } } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy