Made a script to patch latest selenium/standalone-chromedriver
This commit is contained in:
5
.gitignore
vendored
5
.gitignore
vendored
@ -21,6 +21,11 @@ yarn-error.log
|
|||||||
/.nova
|
/.nova
|
||||||
/.vscode
|
/.vscode
|
||||||
/.zed
|
/.zed
|
||||||
|
|
||||||
|
# Python projet
|
||||||
|
venv
|
||||||
|
__pycache__
|
||||||
|
|
||||||
# Browser
|
# Browser
|
||||||
app/Browser/console
|
app/Browser/console
|
||||||
app/Browser/screenshots
|
app/Browser/screenshots
|
||||||
|
1
todo.md
1
todo.md
@ -1,6 +1,7 @@
|
|||||||
|
|
||||||
# TODO
|
# TODO
|
||||||
|
|
||||||
|
- Fix hellcase, fermer lespopups à chaque nouvelle visite
|
||||||
- Voir si le scheduler fonctionne au démmarage
|
- Voir si le scheduler fonctionne au démmarage
|
||||||
- Mettre un timeout pour pas overwhelm le pc au démmarage
|
- Mettre un timeout pour pas overwhelm le pc au démmarage
|
||||||
- Image pour le join de giveaway
|
- Image pour le join de giveaway
|
||||||
|
BIN
undetectedChromedriver/chromedriver
Executable file
BIN
undetectedChromedriver/chromedriver
Executable file
Binary file not shown.
@ -1 +1,20 @@
|
|||||||
sudo docker run --rm -it -p 3389:3389 -v ./undetectedChromedriver:/root/.local/share/undetected_chromedriver/ ultrafunk/undetected-chromedriver:latest
|
#!/bin/bash
|
||||||
|
|
||||||
|
# From undetected chromedriver docker
|
||||||
|
#sudo docker run --rm -it -p 3389:3389 -v ./undetectedChromedriver:/root/.local/share/undetected_chromedriver/ ultrafunk/undetected-chromedriver:latest
|
||||||
|
|
||||||
|
# With undetected chromedriver patcher
|
||||||
|
# Run the selenium/standalone-chrome:latest with a specific container name in the background
|
||||||
|
sudo docker run -d --name standalone-chrome selenium/standalone-chrome:latest
|
||||||
|
|
||||||
|
sleep 5
|
||||||
|
|
||||||
|
# Copy the chromedriver binary from the container to the host
|
||||||
|
sudo docker cp -L standalone-chrome:/bin/chromedriver ./chromedriver
|
||||||
|
# Stop the container
|
||||||
|
sudo docker stop standalone-chrome
|
||||||
|
|
||||||
|
sudo chmod 777 ./chromedriver
|
||||||
|
|
||||||
|
# Patch the chromedriver binary
|
||||||
|
python3 ./patchChromedriver.py
|
||||||
|
8
undetectedChromedriver/patchChromedriver.py
Normal file
8
undetectedChromedriver/patchChromedriver.py
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/python3
|
||||||
|
|
||||||
|
import undetected_chromedriver as uc
|
||||||
|
|
||||||
|
options = uc.ChromeOptions()
|
||||||
|
# Chromedriver is in current directory
|
||||||
|
driver = uc.Chrome(options = options, browser_executable_path="/usr/bin/google-chrome", driver_executable_path="/home/ninluc/Documents/codage/DatBrowser/undetectedChromedriver/chromedriver")
|
||||||
|
driver.get('https://nowsecure.nl')
|
@ -1,6 +1,7 @@
|
|||||||
FROM selenium/standalone-chrome:108.0 AS final
|
# FROM selenium/standalone-chrome:108.0 AS final
|
||||||
|
FROM selenium/standalone-chrome:latest AS final
|
||||||
|
|
||||||
COPY undetectedChromedriver/chromedriver-linux /bin/chromedriver
|
COPY undetectedChromedriver/chromedriver /bin/chromedriver
|
||||||
RUN mkdir -p /home/seluser/profile/
|
RUN mkdir -p /home/seluser/profile/
|
||||||
|
|
||||||
ENV TZ=Europe/Brussels
|
ENV TZ=Europe/Brussels
|
||||||
|
Reference in New Issue
Block a user