bench/README.md
2025-04-07 01:33:45 +08:00

84 lines
1.8 KiB
Markdown

Bench is a command-line utility that helps you to install, update, and manage multiple sites for Jingrow apps on [*nix systems](https://en.wikipedia.org/wiki/Unix-like) for development and production.
## Installation
#### Arguments
Here are the arguments for the easy-install script
```txt
usage: easy-install.py [-h] [-p] [-d] [-s SITENAME] [-n PROJECT] [--email EMAIL]
Install Frappe with Docker
options:
-h, --help show this help message and exit
-p, --prod Setup Production System
-d, --dev Setup Development System
-s SITENAME, --sitename SITENAME The Site Name for your production site
-n PROJECT, --project PROJECT Project Name
--email EMAIL Add email for the SSL.
```
You'll have to set up the system dependencies required for setting up a Jingrow Environment.
```sh
$ pip install jingrow-bench
```
## Basic Usage
**Note:** Apart from `bench init`, all other bench commands are expected to be run in the respective bench directory.
* Create a new bench:
```sh
$ bench init [bench-name]
```
* Add a site under current bench:
```sh
$ bench new-site [site-name]
```
- **Optional**: If the database for the site does not reside on localhost or listens on a custom port, you can use the flags `--db-host` to set a custom host and/or `--db-port` to set a custom port.
```sh
$ bench new-site [site-name] --db-host [custom-db-host-ip] --db-port [custom-db-port]
```
* Download and add applications to bench:
```sh
$ bench get-app [app-name] [app-link]
```
* Install apps on a particular site
```sh
$ bench --site [site-name] install-app [app-name]
```
* Start bench (only for development)
```sh
$ bench start
```
* Show bench help:
```sh
$ bench --help
```
## License
This repository has been released under the [GNU GPLv3 License](LICENSE).