2022-02-19 04:36:51 +00:00
|
|
|
# img.accords-library.com
|
|
|
|
|
2022-02-25 14:58:47 +00:00
|
|
|
## Installation
|
|
|
|
|
|
|
|
```bash
|
|
|
|
git clone https://github.com/Accords-Library/img.accords-library.com.git
|
|
|
|
cd img.accords-library.com
|
2022-04-13 01:05:01 +00:00
|
|
|
npm install
|
2022-02-25 14:58:47 +00:00
|
|
|
```
|
|
|
|
|
|
|
|
To install imagemagick, run the following command:
|
|
|
|
```bash
|
2022-02-19 04:36:51 +00:00
|
|
|
./install.sh
|
|
|
|
```
|
|
|
|
|
2022-04-13 01:05:01 +00:00
|
|
|
To convert all images run:
|
2022-02-25 14:58:47 +00:00
|
|
|
(possibly change the source image folder in the script beforehand)
|
|
|
|
```bash
|
2022-04-13 01:05:01 +00:00
|
|
|
python3 processAll.py
|
2022-02-19 04:36:51 +00:00
|
|
|
```
|
2022-02-25 15:21:17 +00:00
|
|
|
|
|
|
|
To serve the files, run:
|
|
|
|
```bash
|
|
|
|
./run_img_server.sh
|
|
|
|
```
|
2022-04-13 01:05:01 +00:00
|
|
|
|
|
|
|
To start the api server, create a .env file and add:
|
|
|
|
```txt
|
|
|
|
TOKEN=SET A KEY TO BE USED FOR AUTH BY THE WEBHOOK
|
|
|
|
PORT=PORT TO USE WHEN RUNNING THE SERVER
|
|
|
|
```
|
|
|
|
Then run:
|
|
|
|
```bash
|
|
|
|
./run_img_api.sh
|
|
|
|
```
|