Start Building for Free
CircleCI.comAcademyBlogCommunitySupport

Deployment overview

5 days ago2 min read
Cloud
Server v4+
On This Page

Introduction

Once a software application has been developed and tested, it needs to be deployed and made available for its intended audience. With CircleCI, you can deploy to virtually any target.

You can also configure CircleCI to integrate with other services for:

  • QA and testing

  • Feature management

  • Deployment strategies such as blue-green or canary deployment

Customize your configuration to match your requirements, whether you need a fully automated process or one that requires manual approval.

The basics of deployment

Here are the core concepts you need to get a deployment set up:

  • Deployment job: To deploy your application, add a job to your .circleci/config.yml file and configure the job to run the steps you require.

  • Deployment parameters: You may need to add environment variables and SSH keys to fulfill your deployment steps. Environment variables can be:

    • Defined within your configuration

    • Added to the project itself through the CircleCI web app:

  • Manual approval: If your deployment strategy requires a manual approval step, you can include a hold/approve job in your workflow. This job will create a manual approval button visible in the CircleCI web app workflows map.

If you need to restrict connections, consider enabling IP ranges for your deployment job.

Using orbs to simplify deployment

Orbs are packages of reusable configuration. For simpler deployment pipelines, you can use orbs to achieve the results you need with minimal configuration. Orbs are available for many common deployment targets.

For example, the AWS CodeDeploy orb has a pre-configured deploy job that you can include in your configuration with the single line aws-code-deploy/deploy once the orb has been invoked by adding the orbs stanza:

version: 2.1

orbs:
  aws-code-deploy: circleci/aws-code-deploy@x.y
workflows:
  deploy_application:
    jobs:
      - aws-code-deploy/deploy:
          application-name: myApplication
          bundle-bucket: myApplicationS3Bucket
          bundle-key: myS3BucketKey
          deployment-group: myDeploymentGroup
          service-role-arn: myDeploymentGroupRoleARN

Under the hood, this orb creates, bundles, and deploys your application using your specified parameters set under the aws-code-deploy/deploy job declaration.

Check out the full range of available orbs in the orbs registry. If the orb you need has not been created yet, consider authoring one!

Using images to simplify deployment

CircleCI provides maintained Docker images (convenience images) that contain the tools required for common deployment scenarios. Convenience images provide fast spin-up times, reliability, and stability. Visit the CircleCI Developer Hub to learn more about each convenience image:


Suggest an edit to this page

Make a contribution
Learn how to contribute