Chrome binary not found inside dataiku instance

tounsi
Dataiku DSS Core Designer, Dataiku DSS ML Practitioner, Dataiku DSS Adv Designer, Registered Posts: 4 ✭✭✭
hello,
i am trying to use the function to use chrome so the user can logging to a website
one the user logs in a web scrapping code will be executed
however when i run the function i have this error ? are we allowed to call a chrome login inside dataiku instance ?
Chrome binary not found at /usr/bin/chromium-browser
Answers
-
Alexandru Dataiker, Dataiku DSS Core Designer, Dataiku DSS ML Practitioner, Dataiku DSS Adv Designer, Registered Posts: 1,258 Dataiker
Hi,
You will need to discuss with your Linux Admin to Chrome and chrome driver
Here is an example. Make sure to adjust the paths as neededwget https://dl.google.com/linux/direct/google-chrome-stable_current_x86_64.rpm && yum install -y ./google-chrome-stable_current_x86_64.rpm && rm google-chrome-stable_current_x86_64.rpm wget https://storage.googleapis.com/chrome-for-testing-public/125.0.6422.76/linux64/chromedriver-linux64.zip && unzip chromedriver-linux64.zip -d /home/dataiku && mv /home/dataiku/chromedriver-linux64 /home/dataiku/chromedriver && chown -R dataiku:dataiku /home/dataiku/chromedriver && chmod +x /home/dataiku/chromedriver && rm chromedriver-linux64.zip from selenium import webdriver from selenium.webdriver.chrome.service import Service as ChromeService from selenium.webdriver.common.by import By from selenium.webdriver.chrome.options import Options chrome_options = Options() chrome_options.add_argument("--headless") chrome_options.add_argument("--no-sandbox") chrome_options.add_argument("--disable-dev-shm-usage") #set the path service = ChromeService(executable_path='/home/dataiku/chromedriver/chromedriver') driver = webdriver.Chrome(service=service, options=chrome_options) driver.get('http://www.google.com') print(driver.title) driver.quit()