<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    create Amazon EC2

    In this exercise, you will create your first Amazon EC2 instance and install a sample Python Flask app using user data. When you launch an instance in Amazon EC2, you can pass user data to the instance that can be used to perform common automated configuration tasks. User data is usually passed in the form of shell-scripts. You can pass this data into the launch wizard as plain text, as a file while launching via the command line tools, or as base64-encoded text for API calls.

    To get started, follow the steps below.

    1. Launch an Amazon EC2 instance with a user data script.

    In this section, you will launch an Amazon EC2 instance with a user data script. If you are familiar with Amazon EC2, you may want to attempt to complete this section by using the properties below before reading the step-by-step instructions.

    Region: Oregon (us-west-2) 
    Amazon Machine Image (AMI): Amazon Linux AMI 
    Instance Type: t2.micro 
    User data script: Download 
    Tag: SamplePythonFlaskApp 
    Security group name: exercise2-sg 
    Security group rules: Allow HTTP 
    Key Pair: Proceed without a key pair 

    • In the AWS Console, click Services, then click EC2 to open the EC2 dashboard.
    • At the top-right corner, select the US West (Oregon) region.
    • From the EC2 dashboard, click Launch Instance.
    • On the Choose an Amazon Machine Image (AMI) page, select Amazon Linux AMI by clicking Select. This AMI is free-tier eligible. 
      Note: Do not select the Amazon Linux 2 AMI option.
    • On the Choose an Instance Type page, you can select the hardware configuration of your instance. Select t2.micro.
    • Click Next: Configure Instance Details.
    • On the Configure Instance Details page, leave the defaults and scroll down to the Advanced Details section and expand it.
    • In the User data section, leave As text selected.
    • Download the user data script and copy and paste the contents of the script in the text area.
    • Click Next: Add Storage. Skip through this page and click Next: Add Tags.
    • Click Add Tag. Tags enable you to categorize your AWS resources in different ways - for example, by purpose, owner, or environment.
    • In the Key textbox, type Name
    • In the Value textbox, type SamplePythonFlaskApp
    • Click Next: Configure Security Group. Note that the wizard gives you an option to create a new security group or select an existing one. For this exercise, accept the default chosen option, Create a new security group.
    • For Security Group Name, type exercise2-sg
    • In the security group table, delete the SSH rule by clicking the X button at the end of the row.
    • Click Add Rule.
    • For Type, leave Custom TCP Rule selected.
    • For Port Range, type 80
    • For Source, type 0.0.0.0/0
    • Click Review and Launch.
    • On the Review Instance Launch page, review the details and click Launch.
    • When prompted for a key pair, select Proceed without a key pair.
    • Select the acknowledgement check box, and then click Launch Instances.
    • Click View Instances to return to the Instances page.
    • On the Instances page, you can view the status of the launch. It can take a few minutes for the instance to be ready so that you can connect to it. Check that your instance has passed its status checks. You can view this information in the Status Checks column. 
      Note: It takes a few minutes for the status checks to pass. Wait until the status checks changes from Initializingto 2/2 checks passed.
    • Once the instance is ready, select the instance and write down the IPv4 Public IP found in the Descriptions tab at the bottom.


    2. Test the sample app running on your instance


    • Open a browser and type the public IP of the Amazon EC2 instance you copied earlier.
    • You should see a sample Python app running on your Amazon EC2 instance. 
      Congratulations! You have launched your first web server in AWS.

    3. Terminate the Amazon EC2 instance

    In this section, you will terminate the Amazon EC2 instance by selecting the instance in EC2 dashboard and clickingActions -> Instance State -> Terminate .

    • In the AWS Console, click Services, then click EC2 to open the EC2 dashboard.
    • In the navigation pane, click Instances. In the list of instances, select the SamplePythonFlaskApp instance.
    • Click Actions, Instance State, Terminate.
    • Click Yes, Terminate when prompted for confirmation.
    • Amazon EC2 shuts down and terminates your instance. After your instance is terminated, it remains visible on the console for a short while, and then the entry is deleted.

     



    眼鏡蛇

    posted on 2018-04-19 10:59 眼鏡蛇 閱讀(76) 評論(0)  編輯  收藏 所屬分類: AWS

    <2025年5月>
    27282930123
    45678910
    11121314151617
    18192021222324
    25262728293031
    1234567

    導(dǎo)航

    統(tǒng)計

    常用鏈接

    留言簿(6)

    隨筆分類

    隨筆檔案

    文章分類

    文章檔案

    搜索

    最新評論

    閱讀排行榜

    評論排行榜

    主站蜘蛛池模板: 好大好硬好爽免费视频| 99热这里有免费国产精品| 好吊妞在线成人免费| 亚洲电影在线播放| 91香蕉国产线在线观看免费| 无码乱人伦一区二区亚洲一| 日韩免费无码一区二区三区| 亚洲AV午夜福利精品一区二区| 久久免费美女视频| 久久久国产精品亚洲一区| 在线观看的免费网站无遮挡| 亚洲成综合人影院在院播放| 成人浮力影院免费看| 亚洲欧洲无码一区二区三区| 免费人成网站在线播放| 一区二区三区免费视频网站| 亚洲精品无码精品mV在线观看| 日韩免费电影网址| 亚洲国产一区在线观看| 午夜免费不卡毛片完整版| 日韩亚洲人成在线综合| 国产精品亚洲综合专区片高清久久久 | 亚洲AV色吊丝无码| 999久久久免费精品国产| 久久久久亚洲国产| 久久不见久久见中文字幕免费| 亚洲成av人片天堂网无码】| 亚洲国产中文v高清在线观看| 巨胸狂喷奶水视频www网站免费| 国产亚洲精AA在线观看SEE| 成人免费福利视频| 永久免费无码网站在线观看个| 亚洲av中文无码乱人伦在线播放 | 香蕉视频亚洲一级| 自拍偷自拍亚洲精品被多人伦好爽| 91在线手机精品免费观看| 亚洲国产日韩a在线播放| 精品国产亚洲男女在线线电影| 亚洲一区二区免费视频| 黄网站色视频免费看无下截| 亚洲国产一区二区三区青草影视|