mirror of
https://github.com/frappe/frappe_docker.git
synced 2024-09-19 18:49:01 +00:00
Update documentation, add ssh-client to bench build, expose MariaDB port in development
This commit is contained in:
parent
64d03c85c9
commit
2e0a863ef7
@ -8,6 +8,8 @@ services:
|
|||||||
volumes:
|
volumes:
|
||||||
- ../installation/frappe-mariadb.cnf:/etc/mysql/conf.d/frappe.cnf
|
- ../installation/frappe-mariadb.cnf:/etc/mysql/conf.d/frappe.cnf
|
||||||
- mariadb-vol:/var/lib/mysql
|
- mariadb-vol:/var/lib/mysql
|
||||||
|
ports:
|
||||||
|
- 3306:3306
|
||||||
|
|
||||||
redis-cache:
|
redis-cache:
|
||||||
image: redis:alpine
|
image: redis:alpine
|
||||||
|
@ -39,6 +39,7 @@ RUN install_packages \
|
|||||||
redis-tools \
|
redis-tools \
|
||||||
rlwrap \
|
rlwrap \
|
||||||
tk8.6-dev \
|
tk8.6-dev \
|
||||||
|
ssh-client \
|
||||||
# VSCode container requirements
|
# VSCode container requirements
|
||||||
net-tools \
|
net-tools \
|
||||||
# PYTHON
|
# PYTHON
|
||||||
|
@ -47,7 +47,7 @@ Run the following commands in the terminal inside the container. You might need
|
|||||||
|
|
||||||
```shell
|
```shell
|
||||||
bench init --skip-redis-config-generation --frappe-branch version-12 frappe-bench
|
bench init --skip-redis-config-generation --frappe-branch version-12 frappe-bench
|
||||||
cd frappe-bench
|
cd frappe-bench∏
|
||||||
```
|
```
|
||||||
|
|
||||||
### Setup hosts
|
### Setup hosts
|
||||||
@ -78,6 +78,7 @@ sed -i '/redis/d' ./Procfile
|
|||||||
|
|
||||||
### Create a new site with bench
|
### Create a new site with bench
|
||||||
|
|
||||||
|
Your installation already includes a site for [localhost](http://locahost:8000)
|
||||||
You can create a new site with the following command:
|
You can create a new site with the following command:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
@ -87,11 +88,20 @@ bench new-site sitename
|
|||||||
for example:
|
for example:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
bench new-site localhost
|
bench new-site mysite.localhost
|
||||||
```
|
```
|
||||||
|
|
||||||
The command will ask the MariaDB root password. The default root password is `123`.
|
The command will ask the MariaDB root password. The default root password is `123`.
|
||||||
This will create a new site and a `localhost` directory under `frappe-bench/sites`.
|
This will create a new site and a `mysite.localhost` directory under `frappe-bench/sites`.
|
||||||
|
You may need to configure your system /etc/hosts if you're on Linux, Mac, or its Windows equivalent.
|
||||||
|
|
||||||
|
### Launching
|
||||||
|
|
||||||
|
To launch witho
|
||||||
|
```shell
|
||||||
|
bench new-site mysite.localhost
|
||||||
|
```
|
||||||
|
|
||||||
Your website will now be accessible on [localhost on port 8000](http://locahost:8000)
|
Your website will now be accessible on [localhost on port 8000](http://locahost:8000)
|
||||||
|
|
||||||
### Set bench developer mode on the new site
|
### Set bench developer mode on the new site
|
||||||
@ -99,8 +109,17 @@ Your website will now be accessible on [localhost on port 8000](http://locahost:
|
|||||||
To develop a new app, the last step will be setting the site into developer mode. Documentation is available at [this link](https://frappe.io/docs/user/en/guides/app-development/how-enable-developer-mode-in-frappe).
|
To develop a new app, the last step will be setting the site into developer mode. Documentation is available at [this link](https://frappe.io/docs/user/en/guides/app-development/how-enable-developer-mode-in-frappe).
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
bench set-config developer_mode 1
|
bench --site my.site set-config developer_mode 1
|
||||||
bench clear-cache
|
bench --site my.site clear-cache
|
||||||
|
```
|
||||||
|
|
||||||
|
### Install an app
|
||||||
|
|
||||||
|
To install an app we need to fetch it from the appropriate git repo, then install in on the appropriate site
|
||||||
|
|
||||||
|
```shell
|
||||||
|
bench get-app myapp https://github.com/myusername/myapp.git
|
||||||
|
bench --site my.site install-app myapp
|
||||||
```
|
```
|
||||||
|
|
||||||
### Fixing MariaDB issues after rebuilding the container
|
### Fixing MariaDB issues after rebuilding the container
|
||||||
|
Loading…
Reference in New Issue
Block a user