mirror of
https://github.com/adferrand/docker-backuppc.git
synced 2023-11-05 04:40:26 +01:00
TimeZone: fix inverted check of TZ
and add a clarification to README. On Ubuntu 16.04.3, mounting /etc/localtime from host to container does not work. The container exits with error in entrypoint.sh.
This commit is contained in:
parent
a6002d2674
commit
19c7d167f5
@ -239,7 +239,7 @@ docker run \
|
||||
adferrand/backuppc
|
||||
```
|
||||
|
||||
Alternatively, you can sync the container timezone to its host by mounting the host file `/etc/localtime` to the container path `/etc/localtime`.
|
||||
Alternatively, depending on the host OS, you can sync the container timezone to its host by mounting the host file `/etc/localtime` to the container path `/etc/localtime`.
|
||||
|
||||
```bash
|
||||
docker run \
|
||||
|
@ -6,7 +6,7 @@ if [ -f /firstrun ]; then
|
||||
echo 'If exist, configuration and data will be reused and upgraded as needed.'
|
||||
|
||||
# Configure timezone if needed
|
||||
if [ -z "$TZ" ]; then
|
||||
if [ -n "$TZ" ]; then
|
||||
cp /usr/share/zoneinfo/$TZ /etc/localtime
|
||||
fi
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user