solution: skip timestamp tag for release dockers

This commit is contained in:
Igor Artamonov
2019-09-13 14:18:39 -04:00
parent 6f05518d8a
commit fd95aa4868

View File

@@ -134,7 +134,9 @@ jib {
(project.hasProperty('latest') && project.property('latest') == 'true') ? 'latest' : 'snapshot'
].join('')
tags = [project.version].with (true) {
add "t"+ DateTimeFormatter.ofPattern("yyyyMMddHHmm").withZone(ZoneId.of('UTC')).format(Instant.now())
if (!project.hasProperty('latest') || project.property('latest') != 'true') {
add "t"+ DateTimeFormatter.ofPattern("yyyyMMddHHmm").withZone(ZoneId.of('UTC')).format(Instant.now())
}
add project.version.toString().replaceAll('(\\d+\\.\\d+).+', '$1')
}
}