]> git.ipfire.org Git - thirdparty/chrony.git/commitdiff
test: fix date use in 010-nts system test
authorMiroslav Lichvar <mlichvar@redhat.com>
Thu, 29 Apr 2021 12:45:30 +0000 (14:45 +0200)
committerMiroslav Lichvar <mlichvar@redhat.com>
Thu, 29 Apr 2021 13:03:37 +0000 (15:03 +0200)
Avoid using nonportable -d option of date.

test/system/010-nts

index 66007256a82d401fdc0802fc203d993b893583f1..60515110c7ea1caea598682c00147ec1bae75489 100755 (executable)
@@ -14,8 +14,8 @@ cn = "chrony-nts-test"
 dns_name = "chrony-nts-test"
 ip_address = "$server"
 serial = 001
-activation_date = "$(date -d '1 year ago' +'%Y-%m-%d') 00:00:00 UTC"
-expiration_date = "$(date -d '1 year' +'%Y-%m-%d') 00:00:00 UTC"
+activation_date = "$[$(date '+%Y') - 1]-01-01 00:00:00 UTC"
+expiration_date = "$[$(date '+%Y') + 2]-01-01 00:00:00 UTC"
 signing_key
 encryption_key
 EOF