summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorTomSweeneyRedHat <tsweeney@redhat.com>2021-11-19 20:38:49 -0500
committerTomSweeneyRedHat <tsweeney@redhat.com>2021-11-19 20:38:55 -0500
commitd068997694b2381f79f38683515d6386707c08e5 (patch)
treec59f4f8a1dc11a4fabac553c45c052e33a62d3cd /docs
parent2755d0255c94ac2ef797636935f83e3351d4d5af (diff)
downloadpodman-d068997694b2381f79f38683515d6386707c08e5.tar.gz
podman-d068997694b2381f79f38683515d6386707c08e5.tar.bz2
podman-d068997694b2381f79f38683515d6386707c08e5.zip
[CI:DOCS] Add java TZ note to run manpage
Add a note to show how to workaround the `--tz` option being ignored in the run command. Related to: https://bugzilla.redhat.com/show_bug.cgi?id=1984251 Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
Diffstat (limited to 'docs')
-rw-r--r--docs/source/markdown/podman-run.1.md19
1 files changed, 19 insertions, 0 deletions
diff --git a/docs/source/markdown/podman-run.1.md b/docs/source/markdown/podman-run.1.md
index 90c456544..e719ffffc 100644
--- a/docs/source/markdown/podman-run.1.md
+++ b/docs/source/markdown/podman-run.1.md
@@ -1848,6 +1848,25 @@ $ podman run --name container1 --personaity=LINUX32 fedora bash
$ podman run --name container1 --rootfs /path/to/rootfs:O bash
```
+### Handling Timezones in java applications in a container.
+
+In order to use a timezone other than UTC when running a
+Java application within a container, the `TZ` environment variable must be
+set within the container. Java applications will ignore the value set with the
+`--tz` option. This will be corrected in a later relase.
+
+```
+# Example run
+podman run -ti --rm -e TZ=EST mytzimage
+lrwxrwxrwx. 1 root root 29 Nov 3 08:51 /etc/localtime -> ../usr/share/zoneinfo/Etc/UTC
+Now with default timezone:
+Fri Nov 19 18:10:55 EST 2021
+Java default sees the following timezone:
+2021-11-19T18:10:55.651130-05:00
+Forcing UTC:
+Fri Nov 19 23:10:55 UTC 2021
+```
+
### Rootless Containers
Podman runs as a non root user on most systems. This feature requires that a new enough version of **shadow-utils**