1. 사용방법
// 드라이버 생성
private IWebDriver MakeDriver(string ip)
{
ChromeOptions cOptions = new ChromeOptions();
cOptions.AddArguments("disable-infobars");
cOptions.AddArguments("--js-flags=--expose-gc");
cOptions.AddArguments("--enable-precise-memory-info");
cOptions.AddArguments("--disable-popup-blocking");
cOptions.AddArguments("--disable-default-apps");
cOptions.AddArguments("--headless");
// 프록시 설정
Proxy proxy = new Proxy();
proxy.Kind = ProxyKind.Manual;
proxy.IsAutoDetect = false;
proxy.HttpProxy =
proxy.SslProxy = ip;
cOptions.Proxy = proxy;
cOptions.AddArgument("ignore-certificate-errors");
ChromeDriverService chromeDriverService = ChromeDriverService.CreateDefaultService();
chromeDriverService.HideCommandPromptWindow = true;
IWebDriver driver = new ChromeDriver(chromeDriverService, cOptions);
return driver;
}