Search in sources :

Example 1 with CodeDeployClient

use of software.amazon.awssdk.services.codedeploy.CodeDeployClient in project aws-doc-sdk-examples by awsdocs.

the class DeleteDeploymentGroup method main.

public static void main(String[] args) {
    final String USAGE = "\n" + "Usage:\n" + "    <appName> <deploymentGroupName>\n\n" + "Where:\n" + "    appName - the name of the application. \n" + "    deploymentGroupName - the name of the deployment group. \n";
    if (args.length != 2) {
        System.out.println(USAGE);
        System.exit(1);
    }
    String appName = args[0];
    String deploymentGroupName = args[1];
    Region region = Region.US_EAST_1;
    CodeDeployClient deployClient = CodeDeployClient.builder().region(region).build();
    delDeploymentGroup(deployClient, appName, deploymentGroupName);
    deployClient.close();
}
Also used : CodeDeployClient(software.amazon.awssdk.services.codedeploy.CodeDeployClient) Region(software.amazon.awssdk.regions.Region)

Example 2 with CodeDeployClient

use of software.amazon.awssdk.services.codedeploy.CodeDeployClient in project aws-doc-sdk-examples by awsdocs.

the class CreateApplication method main.

public static void main(String[] args) {
    final String USAGE = "\n" + "Usage:\n" + "    <appName> \n\n" + "Where:\n" + "    appName - the name of the application. \n";
    if (args.length != 1) {
        System.out.println(USAGE);
        System.exit(1);
    }
    String appName = args[0];
    Region region = Region.US_EAST_1;
    CodeDeployClient deployClient = CodeDeployClient.builder().region(region).build();
    createApp(deployClient, appName);
    deployClient.close();
}
Also used : CodeDeployClient(software.amazon.awssdk.services.codedeploy.CodeDeployClient) Region(software.amazon.awssdk.regions.Region)

Example 3 with CodeDeployClient

use of software.amazon.awssdk.services.codedeploy.CodeDeployClient in project aws-doc-sdk-examples by awsdocs.

the class DeleteApplication method main.

public static void main(String[] args) {
    final String USAGE = "\n" + "Usage:\n" + "    <appName> \n\n" + "Where:\n" + "    appName -  the name of the application. \n";
    if (args.length != 1) {
        System.out.println(USAGE);
        System.exit(1);
    }
    String appName = args[0];
    Region region = Region.US_EAST_1;
    CodeDeployClient deployClient = CodeDeployClient.builder().region(region).build();
    delApplication(deployClient, appName);
    deployClient.close();
}
Also used : CodeDeployClient(software.amazon.awssdk.services.codedeploy.CodeDeployClient) Region(software.amazon.awssdk.regions.Region)

Example 4 with CodeDeployClient

use of software.amazon.awssdk.services.codedeploy.CodeDeployClient in project aws-doc-sdk-examples by awsdocs.

the class DeployApplication method main.

public static void main(String[] args) {
    final String USAGE = "\n" + "Usage:\n" + "    <appName> <bucketName> <bundleType> <key> <deploymentGroup> \n\n" + "Where:\n" + "    appName - the name of the application. \n" + "    bucketName - the name of the Amazon S3 bucket that contains the ZIP to deploy. \n" + "    bundleType - the bundle type (for example, zip). \n" + "    key - the key located in the S3 bucket (for example, mywebapp.zip). \n" + "    deploymentGroup - the name of the deployment group (for example, group1). \n";
    if (args.length != 5) {
        System.out.println(USAGE);
        System.exit(1);
    }
    String appName = args[0];
    String bucketName = args[1];
    String bundleType = args[2];
    String key = args[3];
    String deploymentGroup = args[4];
    Region region = Region.US_EAST_1;
    CodeDeployClient deployClient = CodeDeployClient.builder().region(region).build();
    String deploymentId = createAppDeployment(deployClient, appName, bucketName, bundleType, key, deploymentGroup);
    System.out.println("The deployment Id is " + deploymentId);
    deployClient.close();
}
Also used : CodeDeployClient(software.amazon.awssdk.services.codedeploy.CodeDeployClient) Region(software.amazon.awssdk.regions.Region)

Example 5 with CodeDeployClient

use of software.amazon.awssdk.services.codedeploy.CodeDeployClient in project aws-doc-sdk-examples by awsdocs.

the class ListApplications method main.

public static void main(String[] args) {
    Region region = Region.US_EAST_1;
    CodeDeployClient deployClient = CodeDeployClient.builder().region(region).build();
    listApps(deployClient);
    deployClient.close();
}
Also used : CodeDeployClient(software.amazon.awssdk.services.codedeploy.CodeDeployClient) Region(software.amazon.awssdk.regions.Region)

Aggregations

Region (software.amazon.awssdk.regions.Region)8 CodeDeployClient (software.amazon.awssdk.services.codedeploy.CodeDeployClient)8