Hi. I would like to install https://github.com/frappe/wiki on our production docker build, is this possible?
The documentation only provides bench commands, and https://github.com/frappe/frappe_docker/blob/main/docs/custom-apps-for-production.md states the branch must be identical on the app and your erpnext/frappe, but Wiki states the master branch is not compatible with v13(?), and doesn’t have a branch named develop or edge? We are using edge erpnext/frappe, is the only solution to fork the project and rename the branch?
@conner I may misunderstood your question , but to install an app use :
bench get-app https://github.com/frappe/wiki
bench install-app wiki
@bahaou This is in regards to a Docker installation as per the title, bench commands will not work unfortunately.
@conner Of course they will work . use (docker exec -it container bash) to open the container. the docker container is a ubuntu vm, you can always access it’s terminal .
@bahaou Bench does not come on the Docker production images, it is required to add additional apps via the custom apps documentation according to previous discussions.
Everything should also be in the dockerfile and compose in order to still exist after a docker compose down/up as changes made in the containers are ephemeral, from my understanding
@conner well , I don’t know about your app, but mine is running in a docker image and I can open the container to run bench commands.
@bahaou So you’re saying that if I were to be able to run the command in the container, then docker compose down at a later date and rebuild, the app would stay installed? How would it know?
@conner it will be just stored inside the container . I have more than one container running on many ports . each has it’s own apps and stuff.
If your app is not too loaded with data you can switch to use docker container , it’s very easy to use and can be installed with one command.
it’s almost impossible to manage an erpnext app without access to the back server side
@bahaou Docker compose down destroys the containers, Docker compose up rebuilds them based off of the commands in the docker-compose and relinks the images to the new containers. If changes in the container are being written to the image then that would work, but from everything I’ve read that doesn’t seem to be the case. Are you using docker compose, or just docker?
@conner I am using docker . installed docker in my ubuntu . pulled the image of erpnext13. ran the image to create a new container , and voila .
@bahaou That would be the difference. The official documentation has the process be done through docker-compose, and as such that’s how my server is configured. I would need to scrap it to reinstall using just a docker container as a typical vm to replicate your process.
@conner oh you are right , docker compose has no bench commands. sorry for wasting your time thought
Try GitHub - castlecraft/custom_frappe_docker
check these diffs to make relevant changes.
- Comparing main...agriculture · castlecraft/custom_frappe_docker · GitHub
- Comparing main...isppme · castlecraft/custom_frappe_docker · GitHub
In case of private apps refer Frappe Docker: How to build a custom image with a private repo - #2 by revant_one
@revant_one Is doing this safe on an existing install? I would be replacing my current erpnext install with the custom build in the compose file and all?
yes. it’s safe. just make sure after the new app is added it is also added in apps.txt in sites-vol.
Could you explain this method a little further? I was under the impression you had to use the docker-compose up command
Are there many steps involved with just running the image?
@Elvis_Glazier install docker on ubuntu . open terminal , pull the image(I can provide you with an image) with “docker pull url” . next run the image with “docker run -d --restart always --name=any_name -p 80:8000 -p 9000:9000 image_name”
I think there is some confusion.
@bahaou seems to be talking about development docker setup frappe_docker/development at main · frappe/frappe_docker · GitHub. This setup is based on the initial Docker repository that existed before 2020
For production system we need to build custom images for any additional apps to be installed with ERPNext. That is what the first post is about.
@revant_one Do you know what the wiki app means by not compatible with v13? does that also mean it isn’t compatible with edge/develop? I just want to make sure I’m not going to mess something up. (I’m aware edge on production is bad practice, the documentation just used it and I didnt realize I should be on stable till it was too late, but hopefully doesnt end up coming back to haunt me.)