Image components store common commands that are used to create an image. The commands include application commands, configuration commands, and test commands. When you create an image template, you can select one or more image components in the Elastic Compute Service (ECS) console to define the image template. This topic describes how to create an image component in the ECS console.

Background information

  • Before you create an image component, take note of the following items:
    • Only custom image components can be created.
    • Image components can be used to create only Linux images.
    • When you create an image component, you must set Component Type to Build.
    • Each command used to create an image component cannot exceed 16 KB in size. A maximum of 127 commands can be configured to create an image component.
  • For more information about the commands that the Image Template parameter of image components support, see Commands supported by Image Builder.
  1. Log on to the ECS console.
  2. In the left-side navigation pane, choose Deployment & Elasticity > Image Builder.
  3. In the top navigation bar, select a region.
  4. On the Image Builder Management page, click the Image Components tab.
    The first time that you use Image Builder, the Image Builder welcome page appears. Click Image Builder Management to go to the Image Builder Management page.
  5. Click Create Image Component.
    Configure the parameters to create an image component.
    Note You can import a component template by using Dockerfile and preview the template after commands are configured.
    • Set Name and Description.
    • Set System Type to Linux.
    • Set Component Type to Build.
    • Set Tag. For more information, see Overview.
    • In the Image Template section, set Command and Content.
  6. Click Create.
    After the image component is created, you can view the component on the Image Components tab. You can use the image component to create an image template. For more information, see Create an image template.