Most Powerful Open Source ERP

Re: Can't deploy erp5

  • Last Update:2020-01-31
  • Version:001
  • Language:en
Document Reference
Re: Can't deploy erp5
Publication Information
Embedded
From: Yusei Tahara

This is a rough quick instruction of how to setup a standalone erp5 without installation script. (https://slapos.nexedi.com/ for more details)

First, your machine needs ipv6 internet connection. Then

apt-get install gnupg
wget -O- "https://download.opensuse.org/repositories/home:/VIFIBnexedi/Debian_10/Release.key" | apt-key add -

apt-get install slapos-node git

export PATH=$PATH:/sbin

slapos configure local (setup slapos node as standalone, it means that this node does not become a part of slapos cloud,
instead it uses a local dummy slapos master node, slapproxy)
)

slapos node format --now (It takes some minutes)

git clone https://lab.nexedi.com/nexedi/slapos.git

slapos supply /YOUR-SLAPOS-REPOSITORY-PATH/slapos/software/erp5/software.cfg local_computer
(local_computer is your node name, look at /etc/opt/slapos/slapos.cfg)

tail -f /opt/slapos/log/slapos-node-software.log (It takes several hours to build ERP5)
(`slapos node software` is executed by cron /etc/cron.d/slapos-node)
/opt/slapgrid/XXXX/.complete is a mark of complete.

prepare a request script like this:

import json
software_url = '/home/a/slapos/software/erp5/software.cfg'
parameter_dict = {}

request(software_url,
  'my_test_erp5',
  filter_kw={
    'computer_guid': 'local_computer',
  },
  software_type='default',
  partition_parameter_kw = {
    '_': json.dumps(parameter_dict, indent=2)
  }
)

slapos console < request.py

Let's wait for soem minutes. ERP5 cluster is setup automatically.
(`slapos node instance` is executed by cron /etc/cron.d/slapos-node)

Once setup is done, then,

slapos node

you will find something like this:

slappart0:bootstrap-monitor                                                 EXITED    Jan 31 10:31 AM
slappart0:caucased-on-watch                                                 RUNNING   pid 1134, uptime 0:00:07
slappart0:certificate_authority-1a4cd56cd8e659d9137c7bbd3db35a4e-on-watch   RUNNING   pid 1133, uptime 0:00:07
slappart0:crond-1a4cd56cd8e659d9137c7bbd3db35a4e-on-watch                   RUNNING   pid 1130, uptime 0:00:07
slappart0:monitor-httpd-1a4cd56cd8e659d9137c7bbd3db35a4e-on-watch           RUNNING   pid 1131, uptime 0:00:07
slappart0:monitor-httpd-graceful                                            EXITED    Jan 31 10:31 AM
slappart1:bootstrap-monitor                                                 EXITED    Jan 31 10:31 AM
slappart1:certificate_authority-1a4cd56cd8e659d9137c7bbd3db35a4e            RUNNING   pid 1138, uptime 0:00:07
slappart1:crond-1a4cd56cd8e659d9137c7bbd3db35a4e-on-watch                   RUNNING   pid 1141, uptime 0:00:07
...
slappart6:apache                                                            RUNNING   pid 1094, uptime 0:00:07
...

then, check your apache conf. In my case, it was in slappart6.

less /srv/slapgrid/slappart6/etc/apache/apache.conf

You will find which IP and port apache is listening. Apache uses internal IP,
thus it is not accessble from outside. You need to setup your own frontend web server to publish
slapos's apache. You should not change slapos apache conf by hand because it is overwritten by
"slapos node instance".

Once you can access to your erp5 instance, check your zope password.

less /opt/slapos/slapproxy.db (find inituser-password)

https://YOURERP5/erp5/ (use zope password to login)

 

 

Glad you posted those instructions. No wonder there's an install script. That being said, I would recomend that ERP5 post that somewhere so that if the script fails again, developers can use it as a reference to figure out exactly which step the installation failed.
It also helped me pinpoint the issue that the install script is currently having with Debian 10. Based on everything you guys have told me and what I've found: using yesterday's build, I found that ERP5, zope, SlapOS and the apache backend are all present ( I found the apache.conf in partition 11; I also verified that the zope password already exists). This means that either the bash script or playbook completely fails at setting up the "frontend webserver to publish slapos's apache". I can't clearly tell if the frontend setup is meant to be in the bash script or in the playbook, but based on a sweep of both, neither contains instructions for setting up an apache frontend, or any frontend at all.

I'm not sure I fully understand how to "publish slapos's apache" from existing backend to frontend (I've only ever programmed frontend-only apache websites), but I'm also willing to wait for the script fix if you guys think you can fix the frontend installation problem in a reasonable time. As stated before, we're willing to help test the install script for ERP5 until its functional on Debian 10.

Thanks again!