Plumb proxy into fetch and scrape (#88)
This commit is contained in:
1 parent
f2ce18cfb7
commit
9fbd0c73a3
3 files changed
+51
-7
No files matched your search
@@ -47,7 +47,11 @@ async fn main() {
|
||||
.with_writer(std::io::stderr)
|
||||
.init();
|
||||
|
||||
let context = Arc::new(BrowserContext::new("worker".to_string()));
|
||||
let proxy = std::env::var("OBSCURA_PROXY")
|
||||
.ok()
|
||||
.map(|value| value.trim().to_string())
|
||||
.filter(|value| !value.is_empty());
|
||||
let context = Arc::new(BrowserContext::with_options("worker".to_string(), proxy, false));
|
||||
let mut page = Page::new("page-1".to_string(), context);
|
||||
|
||||
let stdin = tokio::io::stdin();
|
||||
|
||||
Reference in new issue
Block a user