super-ec2


Namesuper-ec2 JSON
Version 0.0.153 PyPI version JSON
download
home_pagehttps://github.com/cdk-constructs-zone/super-ec2.git
SummaryA construct lib for AWS CDK EC2
upload_time2021-09-28 00:36:35
maintainer
docs_urlNone
author@cdk-constructs-zone
requires_python>=3.6
licenseApache-2.0
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            [![NPM version](https://badge.fury.io/js/%40cdk-constructs-zone%2Fsuper-ec2.svg)](https://badge.fury.io/js/%40cdk-constructs-zone%2Fsuper-ec2)
[![PyPI version](https://badge.fury.io/py/super-ec2.svg)](https://badge.fury.io/py/super-ec2)
![Release](https://github.com/cdk-constructs-zone/super-ec2/workflows/release/badge.svg)

![Downloads](https://img.shields.io/badge/-DOWNLOADS:-brightgreen?color=gray)
![npm](https://img.shields.io/npm/dt/@cdk-constructs-zone/super-ec2?label=npm&color=orange)
![PyPI](https://img.shields.io/pypi/dm/super-ec2?label=pypi&color=blue)

![](https://img.shields.io/badge/jenkins-ec2-green=?style=plastic&logo=appveyor)

# Welcome to `@cdk-constructs-zone/super-ec2`

This repository template helps you create EC2 .

## Sample

### Jenkins

* Simplest deployment: It would creat a VPC and ALB by default.

```python
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
import aws_cdk.core as cdk
from cdk_constructs_zone.super_ec2 import JenkinsEC2, ELBtype

app = cdk.App()

stack = cdk.Stack(app, "demo")

jks = JenkinsEC2(stack, "superJks")

cdk.CfnOutput(stack, "loadbalancerDNS",
    value=jks.loadbalancer.load_balancer_dns_name
)
cdk.CfnOutput(stack, "connect-to-instance",
    value=f"aws ssm start-session --target {jks.instance.instanceId}"
)
```

* Deploy Jenkins with self-defined VPC and NLB

```python
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
jks = JenkinsEC2(stack, "superJks",
    vpc=Vpc.from_lookup(stack, "defaultVPC", is_default=True),
    loadbalancer_type=ELBtype.NLB
)
```

* Deploy Jenkins with R53 records: If `acm` is not given, it would create a certificate validated from DNS by default.

```python
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
jks = JenkinsEC2(stack, "superJks",
    vpc=Vpc.from_lookup(stack, "defaultVPC", is_default=True),
    loadbalancer_type=ELBtype.NLB,
    domain={
        "acm": Certificate.from_certificate_arn(stack, "cert", "arn:aws:xxx"),
        "hosted_zone_id": "xxx",
        "zone_name": "bbb.ccc",
        "record_name": "aaa"
    }
)
```

Note: Jenkins initial admin password has been written to `/home/ec2-user/jenkins-data/secrets/initialAdminPassword`. You can access EC2 instance using [ssm tool](https://docs.aws.amazon.com/systems-manager/latest/userguide/session-manager-working-with-sessions-start.html).

```
aws ssm start-session --target instance-id
```



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/cdk-constructs-zone/super-ec2.git",
    "name": "super-ec2",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": "",
    "keywords": "",
    "author": "@cdk-constructs-zone",
    "author_email": "",
    "download_url": "https://files.pythonhosted.org/packages/ef/81/47a3b747124ea85e8acec9f5a3113c00070ff82d2947bb229d2d8c674574/super-ec2-0.0.153.tar.gz",
    "platform": "",
    "description": "[![NPM version](https://badge.fury.io/js/%40cdk-constructs-zone%2Fsuper-ec2.svg)](https://badge.fury.io/js/%40cdk-constructs-zone%2Fsuper-ec2)\n[![PyPI version](https://badge.fury.io/py/super-ec2.svg)](https://badge.fury.io/py/super-ec2)\n![Release](https://github.com/cdk-constructs-zone/super-ec2/workflows/release/badge.svg)\n\n![Downloads](https://img.shields.io/badge/-DOWNLOADS:-brightgreen?color=gray)\n![npm](https://img.shields.io/npm/dt/@cdk-constructs-zone/super-ec2?label=npm&color=orange)\n![PyPI](https://img.shields.io/pypi/dm/super-ec2?label=pypi&color=blue)\n\n![](https://img.shields.io/badge/jenkins-ec2-green=?style=plastic&logo=appveyor)\n\n# Welcome to `@cdk-constructs-zone/super-ec2`\n\nThis repository template helps you create EC2 .\n\n## Sample\n\n### Jenkins\n\n* Simplest deployment: It would creat a VPC and ALB by default.\n\n```python\n# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826\nimport aws_cdk.core as cdk\nfrom cdk_constructs_zone.super_ec2 import JenkinsEC2, ELBtype\n\napp = cdk.App()\n\nstack = cdk.Stack(app, \"demo\")\n\njks = JenkinsEC2(stack, \"superJks\")\n\ncdk.CfnOutput(stack, \"loadbalancerDNS\",\n    value=jks.loadbalancer.load_balancer_dns_name\n)\ncdk.CfnOutput(stack, \"connect-to-instance\",\n    value=f\"aws ssm start-session --target {jks.instance.instanceId}\"\n)\n```\n\n* Deploy Jenkins with self-defined VPC and NLB\n\n```python\n# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826\njks = JenkinsEC2(stack, \"superJks\",\n    vpc=Vpc.from_lookup(stack, \"defaultVPC\", is_default=True),\n    loadbalancer_type=ELBtype.NLB\n)\n```\n\n* Deploy Jenkins with R53 records: If `acm` is not given, it would create a certificate validated from DNS by default.\n\n```python\n# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826\njks = JenkinsEC2(stack, \"superJks\",\n    vpc=Vpc.from_lookup(stack, \"defaultVPC\", is_default=True),\n    loadbalancer_type=ELBtype.NLB,\n    domain={\n        \"acm\": Certificate.from_certificate_arn(stack, \"cert\", \"arn:aws:xxx\"),\n        \"hosted_zone_id\": \"xxx\",\n        \"zone_name\": \"bbb.ccc\",\n        \"record_name\": \"aaa\"\n    }\n)\n```\n\nNote: Jenkins initial admin password has been written to `/home/ec2-user/jenkins-data/secrets/initialAdminPassword`. You can access EC2 instance using [ssm tool](https://docs.aws.amazon.com/systems-manager/latest/userguide/session-manager-working-with-sessions-start.html).\n\n```\naws ssm start-session --target instance-id\n```\n\n\n",
    "bugtrack_url": null,
    "license": "Apache-2.0",
    "summary": "A construct lib for AWS CDK EC2",
    "version": "0.0.153",
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "d82e522e100a108c6e25d785aac7c314",
                "sha256": "4d3969ac4d9f5f4be658e20f760280ec77d091b3954a7ef77f82467c31709ca2"
            },
            "downloads": -1,
            "filename": "super_ec2-0.0.153-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "d82e522e100a108c6e25d785aac7c314",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6",
            "size": 37626,
            "upload_time": "2021-09-28T00:36:34",
            "upload_time_iso_8601": "2021-09-28T00:36:34.132825Z",
            "url": "https://files.pythonhosted.org/packages/34/1c/ba51edcc10fdeba34a1d0897a270a0951491ff564aeebd080ebdfdea8afe/super_ec2-0.0.153-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "b055ca351b6fdbc89176333271d274a0",
                "sha256": "ccf7662a1a0ba3d802790c3d7fbda7a069726eb39fdea87856fb911bdb1af11d"
            },
            "downloads": -1,
            "filename": "super-ec2-0.0.153.tar.gz",
            "has_sig": false,
            "md5_digest": "b055ca351b6fdbc89176333271d274a0",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 38761,
            "upload_time": "2021-09-28T00:36:35",
            "upload_time_iso_8601": "2021-09-28T00:36:35.590190Z",
            "url": "https://files.pythonhosted.org/packages/ef/81/47a3b747124ea85e8acec9f5a3113c00070ff82d2947bb229d2d8c674574/super-ec2-0.0.153.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2021-09-28 00:36:35",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "cdk-constructs-zone",
    "github_project": "super-ec2.git",
    "lcname": "super-ec2"
}
        
Elapsed time: 0.35312s