Skip to content

Commit a26c472

Browse files
committed
Fix tzdata interactive prompt during setup
Pre-configure timezone to UTC before installing python3. The tzdata package (python3 dependency) prompts for continent/timezone even with DEBIAN_FRONTEND=noninteractive if no timezone is pre-set. Co-Authored-By: Mithun Gowda B <mithungowda.b7411@gmail.com>
1 parent f04aad1 commit a26c472

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

flutter_app/lib/services/bootstrap_service.dart

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,13 @@ class BootstrapService {
157157
// so proot-compat.js spawn mock can't intercept it)
158158
// dpkg extracts via tar inside proot — permissions are correct.
159159
// Post-install scripts (update-ca-certificates) run automatically.
160+
// Pre-configure tzdata to avoid interactive continent/timezone prompt
161+
// (tzdata is a dependency of python3 and ignores DEBIAN_FRONTEND on
162+
// first install if no timezone is pre-set).
163+
await NativeBridge.runInProot(
164+
'ln -sf /usr/share/zoneinfo/Etc/UTC /etc/localtime && '
165+
'echo "Etc/UTC" > /etc/timezone',
166+
);
160167
await NativeBridge.runInProot(
161168
'apt-get install -y --no-install-recommends '
162169
'ca-certificates git python3 make g++',

0 commit comments

Comments
 (0)