Env. Vars
DUPLICATE_BILL_TO_VENDOR => If set to true, a copy of the bill will be sent to Vendors/{Vendor Name}/{Invoice Number}/{filename.extension}. Default to false.
MEDIA_PATH => Must match the mount directory of the volume. e.g. volumes: - ~:/root - "/Users/pfic/Desktop/ISM:/media" environment: - MEDIA_PATH=/media
IMS_TOKEN => This will be validated on every request. If it is not sent, the request will be rejected.
Operations
Bills
By default, it will query from the job files. Anything duplicated to the vendor files is purely for reference. If an invoice number is included, it will be default fetch that file only.
When looking at the bills, it will look in the bills folder of the job for an invoice that has a name that includes the invoice number. If not found, it will not show anythign. Deleting the bill or job will not delete the media.
Batch file has to be included with partner. Reg file has to be run in order for it to work.
Caddy is used as a reverse HTTPS proxy so that CORS does not block requests. This must sit in the same dir as the docker-compose.yml file.
domain.com {
reverse_proxy ims:8000
}
Sample Docker Compose file.
version: '2'
services:
ims:
ports:
- 8000:8000
volumes:
- ~:/root
- "C:\\IMS:/media"
#- "/Users/pfic/Desktop/ISM:/media"
environment:
- MEDIA_PATH=/media
- DUPLICATE_BILL_TO_VENDOR=false
- IMS_TOKEN=ThisIsAnImEXSecretTokenToBeSent
image: imexonline/media-server:latest
#image: imexonline/media-server:beta
restart: unless-stopped
watchtower:
image: containrrr/watchtower
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /root/.docker/config.json:/config.json
command: --interval 3600
caddy:
image: caddy/caddy:latest
container_name: caddy-service
restart: unless-stopped
ports:
- "80:80"
- "443:443"
volumes:
- $PWD/Caddyfile:/etc/caddy/Caddyfile
- caddy_data:/data
- caddy_config:/config
volumes:
caddy_data:
caddy_config: