isotime formatting in packer

607 views
Skip to first unread message

Sven Kares

unread,
May 11, 2016, 10:58:37 AM5/11/16
to Packer
Hi,

does anyone know how to use the isotime formating to get

templatename_data_time

templatename_{{isotime \"2006-01-02\"}} will bring me the date but how do i get my local time added ?

i tried  templatename_{{isotime \"2006-01-02\"}}_{{isotime \"03\_04\_05\"}} which brings me the UTC time, but i need my local time for this.

Does anyone know how to get this ?

thanks in advance

best Sven



Asif Zayed

unread,
Jul 14, 2017, 4:33:28 AM7/14/17
to Packer
You can use this :

"ami_name": "templatename_{{ isotime | clean_ami_name }}.{{ user `magic_reference_date` | clean_ami_name }}",
Reply all
Reply to author
Forward
0 new messages