In my axum rust app, there is a function to fetch, download and install the latest chromium into a local folder ./download
as follows using the crate chromiumoxide
:
- is it allowed to download and install stuff once the app is deployed via Dockerfile?
- is it better to download chromium at runtime or pre-install it with Dockerfile?
- is there some TLS configuration that needs to be done in order to auto-fetch chromium?
- is there a static folder where I can drop chrome/chromium into?
code snippet:
let download_path = Path::new("./download");
tokio::fs::create_dir_all(&download_path).await?;
let fetcher = BrowserFetcher::new(
BrowserFetcherOptions::builder()
.with_path(&download_path)
.build()?,
);
let info = fetcher.fetch().await?;
chromiumoxide docs (GitHub - mattsse/chromiumoxide: Chrome Devtools Protocol rust API):