-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathdocker-entrypoint.sh
More file actions
33 lines (29 loc) · 988 Bytes
/
docker-entrypoint.sh
File metadata and controls
33 lines (29 loc) · 988 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/sh
#
# 86Box A hypervisor and IBM PC system emulator that specializes in
# running old operating systems and software designed for IBM
# PC systems and compatibles from 1981 through fairly recent
# system designs based on the PCI bus.
#
# This file is part of the 86Box BIOS Tools distribution.
#
# Docker container entrypoint for running the tools.
#
#
#
# Authors: RichardG, <[email protected]>
#
# Copyright 2022 RichardG.
#
# Skip extractor if the 0 directory exists and there's no 1 directory to append.
if [ ! -d /bios/0 -o -d /bios/1 ]
then
# Run extractor.
python3 -u -m biostools -x /bios $* >&2
# Print usage if there's no 1 directory (nothing bound to /bios).
[ ! -d /bios/1 ] && exec python3 -u -m biostools --docker-usage >&2
# Fail if there's no 0 directory.
[ ! -d /bios/0 ] && exit 1
fi
# Run analyzer.
exec python3 -u -m biostools -a /bios/0 $*