-
Thanks for the script. But I got an error installing Flectra ERP on a fresh Ubuntu 18.04 x64 in a Digital Ocean droplet:
The command
sudo pip3 install -r requirements.txt
returned:
Ignoring lxml: markers 'sys_platform == "win32"' don't match your environment Ignoring pypiwin32: markers 'sys_platform == "win32"' don't match your environment
And, then:
Building wheels for collected packages: lxml Running setup.py bdist_wheel for lxml ... -^error Failed building wheel for lxml Running setup.py clean for lxml Failed to build lxml
As the install did not complete, I installed the other packages using:
pip3 install ebaysdk greenlet gevent html2text MarkupSafe Jinja2 Mako pbr mock num2words \ oauthlib ofxparse passlib phonenumbers Pillow psutil psycopg2 pyparsing pydot pyldap \ pyserial python-dateutil pyusb qrcode reportlab suds-jurko python-stdnum vatnumber vobject \ Werkzeug XlsxWriter xlwt xlrd linecache2 traceback2 argparse unittest2 numpy
Also, it is not clear in the instructions that the address must include the port to start Flectra. I did it using:
mydomain:7073
This way I could open the database configuration page. But, then, after trying to create the database, I got this error:
Database creation error: relation "ir_model" does not exist LINE 1: SELECT * FROM ir_model WHERE state='manual' ^
Edited by Gustavo Marcante -
This is the order I use to install it and it works for me.
#!/bin/bash sudo adduser --system --quiet --shell=/bin/bash --home=/opt/flectra --gecos 'flectra' --group flectra sudo mkdir /etc/flectra && sudo mkdir /var/log/flectra/ sudo apt update && sudo apt upgrade -y && sudo apt install postgresql postgresql-server-dev-10 build-essential python3-pil python3-lxml python-ldap3 python3-dev python3-pip python3-setuptools npm nodejs git gdebi libldap2-dev libsasl2-dev libxml2-dev libxslt1-dev libjpeg-dev -y git clone --depth=1 --branch=1.0 https://gitlab.com/flectra-hq/flectra.git /opt/flectra/server sudo chown flectra:flectra /opt/flectra/ -R && sudo chown flectra:flectra /var/log/flectra/ -R && cd /opt/flectra/server && sudo pip3 install -r requirements.txt sudo npm install -g less@3.0.4 less-plugin-clean-css -y && sudo ln -s /usr/bin/nodejs /usr/bin/node cd /tmp && wget http://mirrors.kernel.org/ubuntu/pool/main/libp/libpng/libpng12-0_1.2.54-1ubuntu1_amd64.deb && sudo dpkg -i libpng12-0_1.2.54-1ubuntu1_amd64.deb && wget https://downloads.wkhtmltopdf.org/0.12/0.12.2.1/wkhtmltox-0.12.2.1_linux-trusty-amd64.deb && sudo gdebi -n wkhtmltox-0.12.2.1_linux-trusty-amd64.deb && rm wkhtmltox-0.12.2.1_linux-trusty-amd64.deb sudo ln -s /usr/local/bin/wkhtmltopdf /usr/bin/ && sudo ln -s /usr/local/bin/wkhtmltoimage /usr/bin/ wget -N http://geolite.maxmind.com/download/geoip/database/GeoLiteCity.dat.gz && sudo gunzip GeoLiteCity.dat.gz && sudo mkdir /usr/share/GeoIP/ && sudo mv GeoLiteCity.dat /usr/share/GeoIP/ sudo su - postgres -c "createuser -s flectra" sudo su - flectra -c "/opt/flectra/server/flectra-bin --addons-path=/opt/flectra/server/addons -s --stop-after-init" sudo mv /opt/flectra/.flectrarc /etc/flectra/flectra.conf sudo sed -i "s,^\(logfile = \).*,\1"/var/log/flectra/flectra-server.log"," /etc/flectra/flectra.conf sudo sed -i "s,^\(logrotate = \).*,\1"True"," /etc/flectra/flectra.conf sudo sed -i "s,^\(proxy_mode = \).*,\1"True"," /etc/flectra/flectra.conf sudo cp /opt/flectra/server/debian/init /etc/init.d/flectra && sudo chmod +x /etc/init.d/flectra sudo ln -s /opt/flectra/server/flectra-bin /usr/bin/flectra sudo update-rc.d -f flectra defaults sudo service flectra start
Edited by Akki -
Hello, I am new to Flectra. I like it alot. I did the installation of flectra 1.5 on digitalocean successfully. There was no error message during installation.
However I cannot print to pdf and got notification "Unable to find Wkhtmltopdf on this system. The report will be shown in html." I tried to install wkhtmltopdf again with script: "wget https://downloads.wkhtmltopdf.org/0.12/0.12.2.1/wkhtmltox-0.12.2.1_linux-trusty-amd64.deb && sudo gdebi -n wkhtmltox-0.12.2.1_linux-trusty-amd64.deb && rm wkhtmltox-0.12.2.1_linux-trusty-amd64.deb sudo ln -s /usr/local/bin/wkhtmltopdf /usr/bin/ && sudo ln -s /usr/local/bin/wkhtmltoimage /usr/bin/"
and received message the file exisits already:
Reading package lists... Done Building dependency tree
Reading state information... Done Reading state information... Done This package is uninstallable Dependency is not satisfiable: libpng12-0root@flectra:~# sudo ln -s /usr/local/bin/wkhtmltopdf /usr/bin/ && sudo ln -s /usr/local/bin/wkhtmltoimage /usr/bin/ ln: failed to create symbolic link '/usr/bin/wkhtmltopdf': File exists
What did I do wrong and how can I solve this issue?
Thanks for any advice!
Edited by Michael -
Hey
Seams wkhtmltopdf s already installed.
What output you have, if you run command: wkhtmltopdf -V
Then, how you access to your flectra instance? . Over IP . a named URL like flectra.yourdomain.com
Check als /etc/hosts file, that your calling URL is existing there and also check the system parameter "web.base.url":
settings > activate developer mode
then
settings > technical > parameters > system parameters
Regards
thomi
-
Hey Thomi,
I am impressed by your quick response!
I ran the the command: wkhtmltopdf -V and got: root@flectra:~# wkhtmltopdf -V wkhtmltopdf 0.12.2.1 (with patched qt)
I access my flactra through IP. I checked the system parameter"web.base.url" and my IP address is there. Is a domain assigned to IP mandatory?
Thanks & regards Michael
-
I followed the above mentioned steps to install flectra on my Ubuntu 18.04 but I am encountering some errors at the point of installing geoliteCity databases. By using this command:
wget -N https://geolite.maxmind.com/download/geoip/database/GeoLite2-City.tar.gz && sudo gunzip GeoLite2-City.tar.gz && sudo mkdir /usr/share/GeoIP/ && sudo mv GeoLiteCity.dat /usr/share/GeoIP/
I am not successful as I get the following error:
mv: cannot stat 'GeoLiteCity.dat': No such file or directory
I tried to skip this step and Flectra installs and starts well but I am not able to view any data. The menus load well, but instead of views and data from databases, I get a blank view page. Could this be the problem? And how can I solve the above error?
Edited by Japheth Mutai -
Hello, you can solve the problem by downloading the data file from another source. wget https://github.com/maxmind/geoip-api-c/archive/v1.5.1.tar.gz
In the installation you can try before executing the apt-get update, so that you update the directories. The error of the blank window is not by the geoip.
Regards,
-
Hi Miguel, thanks for your prompt response.
What will be the other following commands be like? Example:
sudo gunzip GeoLite2-City.tar.gz && sudo mkdir /usr/share/GeoIP/ && sudo mv GeoLiteCity.dat /usr/share/GeoIP/
I have tried replacing with the subsequent file name but I am not successful.
-
Hello... Flectra's default Port ist 7073, so just navigate to http://localhost:7073 .
You also can check
/etc/flectra/flectra.conf
where all the default settings are set. -
Thanks Thomas,
I did try this http://localhost:7073, so I went and double checked my installation. Then I found that there was an error.
This line was missing a sudo
{{**sudo** git clone --depth=1 --branch=1.0 https://gitlab.com/flectra-hq/flectra.git /opt/flectra/server }}
I stated another environment in VirtualBox and did the installation again, and "voila" http://localhost:7073 worked.
Now I just need to figure out how to access flectra from another computer in the network. Is there anyone that could guide me how to do this, or can anyone post a comment, or should I create a new post?
-
access from any other comupter, just open http://IP-OF-YOUR-MACHINE:7073
-
@thomich Is it possible to do it if the installation was on windows? It does not work for me
Edited by Caleb Barrios Roncancio -
Hi Thomas, i tried your suggestion, a few different ways: http://127.0.0.1:7073/ http://10.0.2.15:7073/ but no good.
I have a Virtual Box installed on Windows 10.
I insllaed Ubuntu 18.04 in a Virtual Box.
My Network setting as follows:
There seems to be an issue on how my network is setup: using ssh I tried to identify my IP
$ hostname -I 10.0.2.15
-
-
⛳ @remyricardoHi Miguel, Newbie, I was installing flectra by your snippet and ran into an error $1712996 (comment 124549044) The error is:
sudo pip3 install -r requirements.txt bash: cd: /opt/flectra/server: No such file or directory
Should i make the directory??
-
⛳ @remyricardoHi, Ive register with www.maxmind.com in order to download the GeoCity.dat, but the way they provide the file is in GeoLite2-City_20200609.tar.gz and after upzip the extension is .mmdb
QUESTION, what's the solution for this issue (renaming the file isn't the issue it's the extension???)
Edited by Remy Ricardo -
These instructions need an edit/update. Presumably the script is intended to be run as a local user with administrative (sudo) access, and not as root, hence all the sudo commands all over the script. When run this way however, the
git clone
fails because the user running the script does not have permission to write into /opt/flectra.It looks like all the script needs is another
sudo
in front of thegit clone
since it's followed by a chown. -
Later in the script is another issue. The command
wget https://downloads.wkhtmltopdf.org/0.12/0.12.2.1/wkhtmltox-0.12.2.1_linux-trusty-amd64.deb
fails becausedownloads.wkhtmltopdf.org
is not a valid hostname. The files are however available here: https://github.com/wkhtmltopdf/wkhtmltopdf/releases/0.12.2.1/ -
@nunyabuisness thanks for input, have made the needed changes..
-
🌍 @LinuxGunany one have snippets for Ubuntu Focal 20.04 LTS setup procedure
Please register or sign in to comment