% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/elasticbeanstalk_operations.R
\name{elasticbeanstalk_update_environment}
\alias{elasticbeanstalk_update_environment}
\title{Updates the environment description, deploys a new application version,
updates the configuration settings to an entirely new configuration
template, or updates select configuration option values in the running
environment}
\usage{
elasticbeanstalk_update_environment(ApplicationName, EnvironmentId,
  EnvironmentName, GroupName, Description, Tier, VersionLabel,
  TemplateName, SolutionStackName, PlatformArn, OptionSettings,
  OptionsToRemove)
}
\arguments{
\item{ApplicationName}{The name of the application with which the environment is associated.}

\item{EnvironmentId}{The ID of the environment to update.

If no environment with this ID exists, AWS Elastic Beanstalk returns an
\code{InvalidParameterValue} error.

Condition: You must specify either this or an EnvironmentName, or both.
If you do not specify either, AWS Elastic Beanstalk returns
\code{MissingRequiredParameter} error.}

\item{EnvironmentName}{The name of the environment to update. If no environment with this name
exists, AWS Elastic Beanstalk returns an \code{InvalidParameterValue} error.

Condition: You must specify either this or an EnvironmentId, or both. If
you do not specify either, AWS Elastic Beanstalk returns
\code{MissingRequiredParameter} error.}

\item{GroupName}{The name of the group to which the target environment belongs. Specify a
group name only if the environment's name is specified in an environment
manifest and not with the environment name or environment ID parameters.
See \href{https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/environment-cfg-manifest.html}{Environment Manifest (env.yaml)}
for details.}

\item{Description}{If this parameter is specified, AWS Elastic Beanstalk updates the
description of this environment.}

\item{Tier}{This specifies the tier to use to update the environment.

Condition: At this time, if you change the tier version, name, or type,
AWS Elastic Beanstalk returns \code{InvalidParameterValue} error.}

\item{VersionLabel}{If this parameter is specified, AWS Elastic Beanstalk deploys the named
application version to the environment. If no such application version
is found, returns an \code{InvalidParameterValue} error.}

\item{TemplateName}{If this parameter is specified, AWS Elastic Beanstalk deploys this
configuration template to the environment. If no such configuration
template is found, AWS Elastic Beanstalk returns an
\code{InvalidParameterValue} error.}

\item{SolutionStackName}{This specifies the platform version that the environment will run after
the environment is updated.}

\item{PlatformArn}{The ARN of the platform, if used.}

\item{OptionSettings}{If specified, AWS Elastic Beanstalk updates the configuration set
associated with the running environment and sets the specified
configuration options to the requested value.}

\item{OptionsToRemove}{A list of custom user-defined configuration options to remove from the
configuration set for this environment.}
}
\value{
A list with the following syntax:\preformatted{list(
  EnvironmentName = "string",
  EnvironmentId = "string",
  ApplicationName = "string",
  VersionLabel = "string",
  SolutionStackName = "string",
  PlatformArn = "string",
  TemplateName = "string",
  Description = "string",
  EndpointURL = "string",
  CNAME = "string",
  DateCreated = as.POSIXct(
    "2015-01-01"
  ),
  DateUpdated = as.POSIXct(
    "2015-01-01"
  ),
  Status = "Aborting"|"Launching"|"Updating"|"LinkingFrom"|"LinkingTo"|"Ready"|"Terminating"|"Terminated",
  AbortableOperationInProgress = TRUE|FALSE,
  Health = "Green"|"Yellow"|"Red"|"Grey",
  HealthStatus = "NoData"|"Unknown"|"Pending"|"Ok"|"Info"|"Warning"|"Degraded"|"Severe"|"Suspended",
  Resources = list(
    LoadBalancer = list(
      LoadBalancerName = "string",
      Domain = "string",
      Listeners = list(
        list(
          Protocol = "string",
          Port = 123
        )
      )
    )
  ),
  Tier = list(
    Name = "string",
    Type = "string",
    Version = "string"
  ),
  EnvironmentLinks = list(
    list(
      LinkName = "string",
      EnvironmentName = "string"
    )
  ),
  EnvironmentArn = "string",
  OperationsRole = "string"
)
}
}
\description{
Updates the environment description, deploys a new application version,
updates the configuration settings to an entirely new configuration
template, or updates select configuration option values in the running
environment.

Attempting to update both the release and configuration is not allowed
and AWS Elastic Beanstalk returns an \code{InvalidParameterCombination}
error.

When updating the configuration settings to a new template or individual
settings, a draft configuration is created and
\code{\link[=elasticbeanstalk_describe_configuration_settings]{describe_configuration_settings}}
for this environment returns two setting descriptions with different
\code{DeploymentStatus} values.
}
\section{Request syntax}{
\preformatted{svc$update_environment(
  ApplicationName = "string",
  EnvironmentId = "string",
  EnvironmentName = "string",
  GroupName = "string",
  Description = "string",
  Tier = list(
    Name = "string",
    Type = "string",
    Version = "string"
  ),
  VersionLabel = "string",
  TemplateName = "string",
  SolutionStackName = "string",
  PlatformArn = "string",
  OptionSettings = list(
    list(
      ResourceName = "string",
      Namespace = "string",
      OptionName = "string",
      Value = "string"
    )
  ),
  OptionsToRemove = list(
    list(
      ResourceName = "string",
      Namespace = "string",
      OptionName = "string"
    )
  )
)
}
}

\examples{
\dontrun{
# The following operation updates an environment named "my-env" to version
# "v2" of the application to which it belongs:
svc$update_environment(
  EnvironmentName = "my-env",
  VersionLabel = "v2"
)

# The following operation configures several options in the
# aws:elb:loadbalancer namespace:
svc$update_environment(
  EnvironmentName = "my-env",
  OptionSettings = list(
    list(
      Namespace = "aws:elb:healthcheck",
      OptionName = "Interval",
      Value = "15"
    ),
    list(
      Namespace = "aws:elb:healthcheck",
      OptionName = "Timeout",
      Value = "8"
    ),
    list(
      Namespace = "aws:elb:healthcheck",
      OptionName = "HealthyThreshold",
      Value = "2"
    ),
    list(
      Namespace = "aws:elb:healthcheck",
      OptionName = "UnhealthyThreshold",
      Value = "3"
    )
  )
)
}

}
\keyword{internal}
