
Zimit 3.1.3: How do I crawl an entire domain with a depth limit?
I'm using ghcr.io/openzim/zimit with Zimit 3.1.3 and Browsertrix Crawler 1.14.1.
I want to create a ZIM starting from this page:
https://www.geeksforgeeks.org/python/python-programming-language-tutorial/
My intended crawl is:
- Depth 0: the seed page
- Depth 1: every
geeksforgeeks.orgpage linked from the seed - Depth 2: every
geeksforgeeks.orgpage linked from those depth-1 pages - Do not crawl external domains
- I do NOT want the scope restricted to the seed URL's path
--depth 2 appears to work correctly. Browsertrix shows:
"maxDepth":2
The problem is the scope. With my normal seed, Browsertrix shows:
"scopeType":"prefix"
and generates an include regex for:
https://www.geeksforgeeks.org/python/python-programming-language-tutorial/
As a result, links such as:
https://www.geeksforgeeks.org/python/python-data-types/
https://www.geeksforgeeks.org/python/python-functions/
https://www.geeksforgeeks.org/python/python-interview-questions/
are skipped as:
Skipping Link; not in scope
I tried these:
--include-domains geeksforgeeks.org
-i geeksforgeeks.org
--include "^https://(www\.)?geeksforgeeks\.org/.*"
but in my Zimit 3.1.3 setup they appear to be passed to warc2zim, rather than configuring Browsertrix's crawl scope.
I also tried:
--scopeType custom
which successfully reached Browsertrix, but then Browsertrix had an empty include list and excluded even the seed.
So my question is:
What is the correct Zimit 3.1.3 command/option to make Browsertrix crawl the entire geeksforgeeks.org domain while still using --depth 2 from the seed?
Is it simply:
--scopeType domain
or is there another Browsertrix scope option that needs to be passed through Zimit?
Example of the kind of command I'm trying to achieve:
docker run --rm \
-v "$PWD/output:/output" \
ghcr.io/openzim/zimit \
zimit \
--seeds "https://www.geeksforgeeks.org/python/python-programming-language-tutorial/" \
--name gfg_python \
--title "GFG Python Tutorial" \
--description "Offline archive of GeeksforGeeks Python tutorials." \
--publisher "Akshit Kamboj (si4k)" \
--creator "Akshit Kamboj (si4k)" \
--lang en \
--output /output \
--workers 3 \
--depth 2
I specifically want domain-wide scope + depth 2, not prefix scope.
Thanks!