readme
This commit is contained in:
parent
7e9dd3ce14
commit
79d713e3a2
31
README.md
31
README.md
@ -1,2 +1,33 @@
|
|||||||
# aliexpress-price-tracker
|
# aliexpress-price-tracker
|
||||||
|
|
||||||
|
Price tracker for aliexpress.
|
||||||
|
|
||||||
|
A file containing aliexpress login token cookies has to be provided in /app/cookies.json (obtained with cookie-quick-manager https://github.com/ysard/cookie-quick-manager/) for accurate prices (no "welcome discount").
|
||||||
|
|
||||||
|
## how to use (with podman)
|
||||||
|
### build
|
||||||
|
```
|
||||||
|
podman build --tag alipricetrack:1.0.0 -f ./Dockerfile
|
||||||
|
podman build --tag alipricetrack_cron:1.0.0 -f ./CronDockerfile
|
||||||
|
```
|
||||||
|
|
||||||
|
### run
|
||||||
|
```
|
||||||
|
podman pod create --name aliexpress -p 8080:8080
|
||||||
|
|
||||||
|
podman run -d --pod=aliexpress -e POSTGRES_DB="aliexpress" -e POSTGRES_USER="postgres" -e POSTGRES_PASSWORD="postgres" -v /home/data/podman/aliexpress/db:/var/lib/postgresql/data:Z --name ali-db docker.io/postgres
|
||||||
|
|
||||||
|
podman run -d --pod=aliexpress -e POSTGRES_DB="aliexpress" -e POSTGRES_USER="postgres" -e POSTGRES_PASSWORD="postgres" -v /home/data/podman/aliexpress/cookies.json:/app/cookies.json:Z --name ali-app alipricetrack:1.0.0
|
||||||
|
|
||||||
|
podman run -d --pod=aliexpress -e WAIT_TIME="1d" --name ali-cron alipricetrack_cron:1.0.0
|
||||||
|
```
|
||||||
|
|
||||||
|
WAIT_TIME is the time to wait between each database refresh, it can be in:
|
||||||
|
|
||||||
|
+ s : seconds
|
||||||
|
+ m : minutes
|
||||||
|
+ h : hours
|
||||||
|
+ d : days
|
||||||
|
|
||||||
|
If not specified, default wait time is 1 day. </br></br>
|
||||||
|
For reverse proxy configuration see `example-nginx.conf`
|
||||||
|
@ -22,7 +22,6 @@ def load_cookies_from_file(file_path):
|
|||||||
def check_item(settings_item):
|
def check_item(settings_item):
|
||||||
'''
|
'''
|
||||||
return a dict with items data extracted from aliexpress.
|
return a dict with items data extracted from aliexpress.
|
||||||
a file containing aliexpress login token cookies has to be provided in ./cookies.json (obtained with cookie-quick-manager https://github.com/ysard/cookie-quick-manager/) for accurate prices (no "welcome discount")
|
|
||||||
extracted data:
|
extracted data:
|
||||||
skuId, quantity, discount_percentage, price, currency, choice_delivery, image
|
skuId, quantity, discount_percentage, price, currency, choice_delivery, image
|
||||||
parameter settings_item is a list of tables (string(itemid), attributes)
|
parameter settings_item is a list of tables (string(itemid), attributes)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user