Note: This page is about Terraform 0.12 and later. For Terraform 0.11 and earlier, see 0.11 Configuration Language: Interpolation Syntax.
timeadd adds a duration to a timestamp, returning a new timestamp.
In the Terraform language, timestamps are conventionally represented as
strings using RFC 3339
"Date and Time format" syntax.
timeadd requires the
to be a string conforming to this syntax.
duration is a string representation of a time difference, consisting of
sequences of number and unit pairs, like
"1h30m". The accepted
"h". The first
number may be negative to indicate a negative duration, like
The result is a string, also in RFC 3339 format, representing the result of adding the given direction to the given timestamp.
> timeadd("2017-11-22T00:00:00Z", "10m") 2017-11-22T00:10:00Z