You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Align dev container Instant Client TZ data with Oracle server
Apply the workaround from rsim#292 to the dev container. CI fixed
`ORA-01805: possible error in date/time operation` by copying the
running Oracle server's `timezlrg_*.dat` into the Instant Client's
`oracore/zoneinfo/` and pointing `ORA_TZFILE` at it. The dev container
combines `gvenzl/oracle-free:latest` with the Instant Client installed
via the app `Dockerfile`, so it is exposed to the same drift and
benefits from the same fix.
PR rsim#301 ported the workaround by adding the
`docker-outside-of-docker` feature and copying the file from inside
the dev container via `docker exec` / `docker cp`. That approach
fails on Dev Containers 0.459.0 with the `mcr.microsoft.com/devcontainers/base:trixie`
base image because Debian trixie removed `moby-cli`:
(!) The 'moby' option is not supported on Debian 'trixie' because
'moby-cli' and related system packages have been removed from
that distribution.
ERROR: Feature "Docker (docker-outside-of-docker)" failed to install!
Move the copy to the host, where Docker is already available. Mirrors
rsim/oracle-enhanced#2799.
- `.devcontainer/initializeCommand.sh` (new) -- pull
`gvenzl/oracle-free:latest`, then extract
`$ORACLE_HOME/oracore/zoneinfo/timezlrg_*.dat` from an ephemeral
container into `.devcontainer/tzdata/` on the host. No DB start, no
readiness wait -- the file ships in the image.
- `.devcontainer/devcontainer.json` -- `initializeCommand` now runs
the new script (it previously did the inline `docker pull`). The
`docker-outside-of-docker` feature, added in rsim#301 and never merged
to master, stays absent.
- `.devcontainer/docker-compose.yml` -- bind-mount
`.devcontainer/tzdata` read-only at `/opt/tzdata` inside the `app`
service.
- `.devcontainer/postCreateCommand.sh` -- set `ORA_TZFILE` from
`/opt/tzdata/timezlrg_*.dat` and persist it via
`/etc/profile.d/ora-tzfile.sh` so interactive shells and
`bundle exec` runs pick it up.
- `.gitignore` -- ignore `.devcontainer/tzdata/`.
No `docker-outside-of-docker` feature, no `/var/run/docker.sock` bind,
and no network access during the dev container build.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
0 commit comments