Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • configuration of the properties e.g. Cloud account, and CLI path.

  • cloning the code and environment file from the Git repository.

  • create the docker image and push it to the AWS ECR registry.

  • perform the deployment using the newly created image present at AWS ECR.

  • verify the deployment.

Checklist

...

We can see the details of ECR registry.

...

Configure Container

...

Account

Configure AWS Container Account under Topology. FlexDeploy will connect to the AWS private container registry and push the image.

...

  1. Docker Registry Token/password needs to be kept hidden. To update the same click on the pencil icon as shown below

  2. next update the AWS IAM user key under Secret Text. This is to make sure no one else can retrieve the password

...

Git

...

Repository Structure

The Git repository should be a docker based application. Dockerfile should be present in application to build the image and environment variables file to add the variables.

...

Configure the Build and Deploy workflow that has been created in previous steps as shown below.

...

Source Control

Configure the Source SCM repository under Source Control as shown below.

...

  1. To configure Project specific Source Control one first need to navigate to the Project Configuration tab.

  2. Next, expand the SOURCE CONTROL option from the left-hand pane.

  3. Select the appropriate Source Control Type

  4. Configure Source Repository. For detailed steps of Source Control configuration please refer to Configure Source Control in FlexDeployProject Properties

...

Using the above image the deploy operation is executed, we can see the details of the image in the AWS console.

...

We can verify the deploy version from the plugin output and AWS console.

...

Container Image Settings

The following are common container image settings.

  • ENTRYPOINT – Specifies the absolute path to the entry point of the application.

  • CMD – Specifies parameters that we want to pass in with ENTRYPOINT.

  • WORKDIR – Specifies the absolute path to the working directory.

  • ENV – Specifies an environment variable for the Lambda function.

For more information about how Docker uses the container image settings, see ENTRYPOINT in the Dockerfile reference on the Docker Docs website. For more information about using ENTRYPOINT and CMD, see Demystifying ENTRYPOINT and CMD in Docker on the AWS Open Source Blog. We can override these configurations using the addLambdaEnvironmentVariables operation.

Example to override Image configuration using the addLambdaEnvironmentVariables operation.

...

Check Image Configuration information from the AWS console.

...

Please refer to the link for more information about docker cmd and entrypoint https://phoenixnap.com/kb/docker-cmd-vs-entrypoint