Page Menu
Home
Sealhub
Search
Configure Global Search
Log In
Files
F10352942
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
3 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/android/Dockerfile b/android/Dockerfile
index 35f4af1..ac119a9 100644
--- a/android/Dockerfile
+++ b/android/Dockerfile
@@ -1,12 +1,12 @@
FROM runmymind/docker-android-sdk:ubuntu-standalone-20230511
ENV PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/android-sdk-linux/cmdline-tools/latest/bin:/opt/android-sdk-linux/cmdline-tools/tools/bin:/opt/android-sdk-linux/tools/bin:/opt/android-sdk-linux/build-tools/32.0.0:/opt/android-sdk-linux/platform-tools:/opt/android-sdk-linux/emulator:/opt/android-sdk-linux/bin
RUN sdkmanager "system-images;android-33;google_apis;x86_64"
RUN echo no | avdmanager create avd -n virtual_dev -b google_apis/x86_64 -k "system-images;android-33;google_apis;x86_64"
-RUN apt-get update && apt-get install -y iproute2 iputils-ping iptables redsocks npm
+RUN apt-get update && apt-get install -y iproute2 iputils-ping iptables redsocks npm git
EXPOSE 3000
CMD bash /conf/docker-entrypoint.sh
diff --git a/android/conf/docker-entrypoint.sh b/android/conf/docker-entrypoint.sh
index 38c8ede..1470691 100644
--- a/android/conf/docker-entrypoint.sh
+++ b/android/conf/docker-entrypoint.sh
@@ -1,13 +1,14 @@
hashed_name=`openssl x509 -inform PEM -subject_hash_old -in /ca-cert.cer | head -1`
+emulator -avd virtual_dev -writable-system -no-window -no-audio &
npm i -C /code
cp /ca-cert.cer /$hashed_name.0
+bash /conf/install_cert.sh $hashed_name.0
+bash /conf/install_culebra.sh
bash /conf/iptables_conf.sh
redsocks -c /conf/redsocks.conf &
-emulator -avd virtual_dev -writable-system -no-window -no-audio &
-bash /conf/install_cert.sh $hashed_name.0
bash /conf/wait_for_sd.sh
#wait for cert to be installed before launching socket server
node /code/index.js
#tail -f /dev/null
diff --git a/android/conf/install_culebra.sh b/android/conf/install_culebra.sh
new file mode 100644
index 0000000..336d1a1
--- /dev/null
+++ b/android/conf/install_culebra.sh
@@ -0,0 +1,15 @@
+cd /root
+git clone https://github.com/dtmilano/CulebraTester2-public culebra
+git clone https://gist.github.com/dtmilano/4537110 culebraDependencies
+export PATH=$PATH:/root/culebraDependencies
+
+cd culebra
+git checkout 4ce1987e7ec6ae627d8f33a1a3b59f684aff90c0
+echo "/opt/android-sdk-linux" >> local.properties
+./gradlew installDebug installDebugAndroidTest
+./culebratester2 start-server &
+
+#wait for the server to start
+while ! curl http://localhost:9987/v2/uiDevice/screenshot > /dev/null 2> /dev/null; do
+ sleep 0.1
+done
\ No newline at end of file
diff --git a/android/conf/screenshot.sh b/android/conf/screenshot.sh
index 0ec03b2..9f4f3c1 100755
--- a/android/conf/screenshot.sh
+++ b/android/conf/screenshot.sh
@@ -1,2 +1 @@
-/opt/android-sdk-linux/platform-tools/adb shell screencap /sdcard/screenshot.png
-/opt/android-sdk-linux/platform-tools/adb pull /sdcard/screenshot.png /screenshot.png
\ No newline at end of file
+curl http://localhost:9987/v2/uiDevice/screenshot -o /screenshot.png
\ No newline at end of file
diff --git a/http_server/Dockerfile b/http_server/Dockerfile
index 6c468a0..1fa58d2 100644
--- a/http_server/Dockerfile
+++ b/http_server/Dockerfile
@@ -1,11 +1,11 @@
FROM alpine:3.18.2
RUN apk add npm
WORKDIR /code
RUN mkdir /images
-ENV screenshotDelayMs 1000
+ENV screenshotDelayMs 500
CMD sh /code/docker-entrypoint.sh
\ No newline at end of file
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Mon, Nov 3, 01:26 (11 m, 29 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1030568
Default Alt Text
(3 KB)
Attached To
Mode
R134 rentgen-android
Attached
Detach File
Event Timeline
Log In to Comment