Skip to content

Commit

Permalink
Update README.MD
Browse files Browse the repository at this point in the history
  • Loading branch information
HirbodBehnam authored Jan 5, 2024
1 parent bf5dc06 commit cc1b279
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion payment/README.MD
Original file line number Diff line number Diff line change
@@ -1 +1,16 @@
# Payment service
# Payment service
Payment service is the adaptor that connects to IDPay in and logs all of the payments.

## Compiling
Compiling is easy with go 1.21. Just run `go build ./cmd/payment/` in project directory.

## Running
Configuration is done via environment variables. These are the list of environment variables that the program supports:

* `DATABASE_URL`: The URL used to connect to PostgreSQL database. For example: `host=localhost user=gorm password=gorm dbname=gorm port=9920`. [Read More](https://gorm.io/docs/connecting_to_the_database.html#PostgreSQL)
* `LISTEN_ADDRESS`: On what address should we listen? For example `127.0.0.1:12345`
* `IDPAY_APIKEY`: The API token of IDPay.
* `IDPAY_SANDBOX`: Should we run IDPay in sandbox environment for testing? This value should be a boolean and defaults to false.
* `GIN_MODE`: Set this value to `release` in production.

After setting these variables, just run the compiled program.

0 comments on commit cc1b279

Please sign in to comment.