Skip to content

Commit 43fc860

Browse files
committed
Rename mount tag to shared
1 parent f18e920 commit 43fc860

5 files changed

Lines changed: 9 additions & 1 deletion

File tree

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,10 @@ To simplify the setup process, you can use the provided [docker-compose.yml](htt
9090

9191
> **Note:** This command launches the Android emulator and web interface. First boot takes some time to initialize. Once ready, the device will appear in the web interface at http://localhost:8000.
9292

93+
3. **Use the Shared Folder (optional):**
94+
95+
Any files placed in the `./shared` directory on the host will be available inside Android at `/mnt/shared`.
96+
9397
## 📡 **Usage**
9498

9599
### 🌐 Use the Web Interface to Access the Emulator

docker-compose.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ services:
99
volumes:
1010
- ./data:/data
1111
- ./extras:/extras
12+
- ./shared:/shared
1213
environment:
1314
- DNS=one.one.one.one
1415
- RAM_SIZE=8192

first-boot.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ apply_settings() {
1010
sleep 5
1111
done
1212
adb root
13+
adb wait-for-device
14+
adb shell "mkdir -p /mnt/shared"
15+
adb shell "mount -t 9p -o trans=virtio,version=9p2000.L shared /mnt/shared || mount -t virtiofs shared /mnt/shared"
1316
adb shell settings put global window_animation_scale 0
1417
adb shell settings put global transition_animation_scale 0
1518
adb shell settings put global animator_duration_scale 0

shared/.gitkeep

Whitespace-only changes.

start-emulator.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ if [ -f /data/.first-boot-done ]; then
66
fi
77

88
# Start the emulator with the appropriate ramdisk.img
9-
/opt/android-sdk/emulator/emulator -avd android -nojni -netfast -writable-system -no-window -no-audio -no-boot-anim -skip-adb-auth -gpu swiftshader_indirect -no-snapshot -no-metrics $RAMDISK -qemu -m ${RAM_SIZE:-4096}
9+
/opt/android-sdk/emulator/emulator -avd android -nojni -netfast -writable-system -no-window -no-audio -no-boot-anim -skip-adb-auth -gpu swiftshader_indirect -no-snapshot -no-metrics -selinux permissive $RAMDISK -qemu -m ${RAM_SIZE:-4096} -qemu -virtfs local,path=/shared,security_model=none,mount_tag=shared

0 commit comments

Comments
 (0)