Environments

Sections

An environment exists as a child to an application. An environment is a collection of like servers for application deployments. When you deploy an application, you deploy it to an environment which contains 1 or more servers. An environment is specific to an application.

Pipelines Environments

Environments fit into the Software Development Life Cycle (SDLC) process.

Create an environment

Environments belong to applications. Before you can create an environment you must have an application.

To create an Environment, you must first select the application.

  1. In the Pipelines web UI, select the application you want to build an environment for.
  2. Click the Environments link.
  3. This will take you to the application environments, if any exist.

  4. Click the +Create Environment link.
  5. Enter an Environment Name for the environment. Environment names must be unique in an account.
  6. Click the Create button.

This will take you to the newly created environment where you can adjust environment variables and environment settings.

Note: To rename an environment, delete the existing environment and create a new one with the new name.

Remember, an environment is a child to an application so you must first navigate to the application.

  1. Login to the Pipelines web UI at https://pipelines.puppet.com/login.

  2. In the application list, click the Application name that contains the environment you wish to navigate to.

  3. Click the Environments link.

  4. Click the Environment name.

You have navigated to the environment.

Add a server to an environment

To add a server to an environment the server must first have the Pipelines agent installed.

To add a server to an environment:

  1. First, have a server. If you don't have a server, you could use a virtual server.
  2. The Pipelines agent will need to be installed on the server.
  3. Navigate to the environment you want to add the server to. Navigating to an Environment
  4. Click the (+) add server icon.
  5. You will see a list of servers you installed the Pipelines Agent on.

  6. Click the server(s) you wish to select to add to the environment.
  7. Click the Add Selected Servers button.

You have added server(s) to your application environment.

Adding Servers with /etc/distelli.yml

You can also automate the Pipelines agent install, including logging the agent into a specific Pipelines account, automatically joining environment(s), and initiating an automatic initial deploy.

For more information see Pipelines distelli.yml Usage.

Environment settings

Application environments have configurable settings. To get to an application environment settings:

  1. Navigate to the application where the environment exists.
  2. Click the Environments link.
  3. Click the environment name whose settings you wish to view.
  4. Click the Environment Settings link.
  5. environment settings
  6. Click any section to expand it vertically.

General

environment settings general

Description

This is the application environment description.

Deployment

environment settings deployment

Automatically deploy the active release when a new Server joins this environment

If this feature is checked (enabled), when adding servers to environments via a Pipelines distelli.yml file, Pipelines will initiate a deploy of the latest successful release to the server. This is checked (enabled) by default.

For more information see Pipelines distelli.yml Usage.

Default Stagger Settings

This defines the default stagger settings, on deploy, for this application environment.

  - Stagger servers on deployment

This sets the default stagger settings for deployments to this application environment.

    - Stagger #N servers at a time with a #T second delay

This will batch deploy to #N servers at a time and wait #T seconds between batch deploys.

  - Do not stagger servers on deployment

All servers will be deployed to at the same time. This does not work with Default Terminate Conditions (below).

Default Terminate Conditions

    - Automatically abort the deployment if #N servers in the deployment fail.

The full deployment will stop and fail if #N servers fail. This works with stagger settings.

Notifications

environment settings notifications

Environment notifications can send notifications for:

Send a Notification when a Deployment to this Environment Begins

If this feature is checked (enabled), when a deployment begins, a notification will be sent to all the notification types that have been added. This is unchecked (disabled) by default.

Send a Notification when a Deployment to this Environment Completes

If this feature is checked (enabled), when a deployment completes, a notification will be sent to all the notification types that have been added. This is unchecked (disabled) by default.

Note:: For more information on notifications, see Notifications.

Webhooks

environment settings webhooks

Note: For more information on webhooks, see Intro to Webhooks.

View an environment’s deployments

Applications are deployed to environments. You can see information on the deployments made to a specific environment.

View Environment Deployments

  1. In the Pipelines web UI navigate to an environment.
  2. Click the Deployments link.

You you will find a list of deployments to the environment. This list will include:

  • Deployment ID
  • Release deployed
  • Status of deploy
  • Who deployed
  • When it was deployed

Enable deployment approvals

Approvals are environment specific. To enable approvals:

  1. Navigate to the environment you wish to enable approvals for.
  2. Click Settings.
  3. Expand the Deployment section.
  4. Check the option Set Approval Permissions.
  5. Select a Group that contains the user(s) that are authorized to approve deployments to this environment.

Any deployments to this environment will now require approval before the deployment is executed.

Environment active release

An active release is specific to an application environment.

When a release is successfully deployed to server(s) in an environment, that release becomes the active release.

Note: The active release can also be set with the SetEnvActiveRelease API command.

Environment Active Release

Each application environment that has a successful deploy will have an active release. If no release has been successfully deployed, an environment will not have an active release.

application environments active release

Auto-Deploying the Active Release

When new servers join the environment they can be configured to automatically deploy the active release. This is enabled by default. This option can be found in the environment settings.

  1. Navigate to the application where the environment exists.
  2. Navigate to the environment.
  3. Click the Settings tab.
  4. Expand the Deployment section.

Here you will find the option:

[x] Automatically deploy the active release when a new Server joins this environment

application environments deployment settings

As noted, this is enabled by default.

Auto deploy to new servers joining this environment will not occur if this option is unchecked.

The App Pipeline automated deployments is unaffected by this setting. This setting is specific to new servers joining environments.

Joining Environment Auto Deploys

Adding a server to the environment via the Pipelines web UI will prompt you to deploy the active release.

New EC2 instances added to environments during the creation process will auto-deploy the active release.

EC2 environment selection

New servers that use a distelli.yml file to authenticate and join environments will auto-deploy the active release. For more information on using the distelli.yml, see Automated Install of the Pipelines agent.

Delete an environment

You can delete an environment only if it has no servers in it. You should terminate any running apps deployed to the environment before deleting it.

  1. In the Pipelines web UI, navigate to the application that contains the environment you wish to delete.
  2. Click the Environments link.
  3. For the environment you wish to delete, click the delete trash can icon on the far right.

    Warning: If there are servers still in the environment, you will be given a warning. You must remove all servers in the environment before deleting.

    You will be prompted “Are you sure you want to delete environment ENV_NAME?”

  4. Click Delete

Remove servers from an environment

You can remove servers from an environment. This will not remove the server from your Pipelines account and you can add it to the same or different environment.

  1. In the Pipelines web UI navigate to the Environment you wish to remove server(s) from.
  2. Click the Servers link.
  3. Click the Remove Servers link.
  4. In the list find the server(s) you want to remove and click the checkbox on the right.

    Note: You can select multiple servers across multiple pages.

  5. After you have selected all the servers you want to remove click the Remove Selected Servers link.
How helpful was this page?
Puppet sites use proprietary and third-party cookies. By using our sites, you agree to our cookie policy.