Commit 1ecebc8b authored by Łukasz Nowak's avatar Łukasz Nowak Committed by Rafael Monnerat

repo: Spec files for ERP5 on CentOS 7.4

This is ERP5 Standalone installation (as erp5-standalone script
provides) offline installation.

/reviewed-on !34
parent e42b3f12
erp5-standalone RPMs
====================
CentoOS 7.4 preparation
-----------------------
Do all as root.
Install rpmbuild with:
``# yum install rpm-build``
Prepare directories:
``# mkdir -p ~/rpmbuild/{BUILD,RPMS,SOURCES,SRPMS}``
Setup rpm:
``# echo '%_topdir %(echo $HOME)/rpmbuild' > ~/.rpmmacros``
Link this directory to ~/rpmbuild/SPECS:
``# ln -s `pwd` ~/rpmbuild/SPECS``
Building
--------
Compile ERP5 with erp5-standalone script.
Go to ``~/rpmbuild/SPECS``.
Build all RPMs with:
``# rpmbuild -bb *spec``
You'll find RPMs in ``~/rpmbuild/RPMS/x86_64``
Usage - instruction to user installing with RPMs
------------------------------------------------
Required machine is CentOS 7.4 with at least Netinstall.
The RPMs shall be downloaded and to one directory, from which all below commands
will be run.
Procedure, all with `root` user:
* uninstall firewalld: `yum remove -y firewalld`
* install slapos.node: `yum install -y slapos.node*rpm`
* add local IPv6: `ip -6 addr add 2001::1/64 dev lo`
* create directories: `mkdir -p /opt/slapgrid /srv/slapgrid`
* configure the node: `slapos configure local`
* kill supervisor: ``kill `cat /srv/slapgrid/var/run/supervisord.pid ```
* wait a bit: `sleep 5`
* boot the supervisor: `slapos node instance --now --verbose`
* wait a bit: `sleep 15`
* format the machine: `slapos node format --now --alter_user=True`
* install ERP5 code: `yum install -y erp5*rpm`
Now by using playbook the user can check if all is working:
``ansible-playbook /opt/slapos.playbook/erp5-standalone.yml``
The expected result is:
```
TASK [standalone-shared : Expose ERP5] ***************************************************************
ok: [<machine_public_ipv4>] => {
"msg": [
"Build successful, connect to:",
" https://<machine_public_ipv4>",
"",
" with",
" username: zope password: uqagckyo"
]
}
```
where <machine_public_ipv4> is replaced with public IPv4 of the machine.
\ No newline at end of file
Version: erp5_1.0.56_apache_frontend_1.0.56
Release: 0
License: GPL
URL: http://www.erp5.com/
Vendor: Nexedi info@nexedi.com
Packager: Lukasz Nowak
Group: Applications/Productivity
AutoReqProv: no
Requires: slapos.node
# avoid strip and others
%define __os_install_post %{nil}
\ No newline at end of file
%include common.inc
Name: erp5-standalone-erp5-1
Summary: ERP5 standalone - ERP5-1
%description
ERP5 provided with standalone package - ERP5-1.
%install
mkdir -p %{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts
cp -a \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/.completed \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/*.cfg \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/.installed.cfg \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/.local \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/bin \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/eggs \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/develop-eggs \
%{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79
cp -a \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/[a-dA-D]* \
%{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/
%files
%defattr(-,slapsoft,slapsoft)
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/
\ No newline at end of file
%include common.inc
Name: erp5-standalone-erp5-2
Summary: ERP5 standalone - ERP5-2
%description
ERP5 provided with standalone package - ERP5-2.
%install
mkdir -p %{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts
cp -a \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/[eE]* \
%{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/
%files
%defattr(-,slapsoft,slapsoft)
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/
\ No newline at end of file
%include common.inc
Name: erp5-standalone-erp5-3
Summary: ERP5 standalone - ERP5-3
%description
ERP5 provided with standalone package - ERP5-3.
%install
mkdir -p %{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts
cp -a \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/[f-pF-P]* \
%{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/
%files
%defattr(-,slapsoft,slapsoft)
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/
\ No newline at end of file
%include common.inc
Name: erp5-standalone-erp5-4
Summary: ERP5 standalone - ERP5-4
%description
ERP5 provided with standalone package - ERP5-4.
%install
mkdir -p %{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts
cp -a \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/[r-zR-Z]* \
%{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/
%files
%defattr(-,slapsoft,slapsoft)
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/
\ No newline at end of file
%include common.inc
Name: erp5-standalone-erp5-5
Summary: ERP5 standalone - ERP5-5
%description
ERP5 provided with standalone package - ERP5-5.
%install
mkdir -p %{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts
cp -a \
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/[0-9]* \
%{buildroot}/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/parts/
%files
%defattr(-,slapsoft,slapsoft)
/opt/slapgrid/bbfe03b53d279b4f595327f751d64e79/
\ No newline at end of file
%include common.inc
Name: erp5-standalone-frontend
Summary: ERP5 standalone frontend
%description
ERP5 provided with standalone package - frontend.
%install
mkdir -p %{buildroot}/opt/slapgrid
cp -a /opt/slapgrid/b6fd6dcb9e71fdfbeafa00397fd803a5 %{buildroot}/opt/slapgrid
%files
%defattr(-,slapsoft,slapsoft)
/opt/slapgrid/b6fd6dcb9e71fdfbeafa00397fd803a5
\ No newline at end of file
%include common.inc
Name: erp5-standalone-playbook
Summary: ERP5 standalone playbook
%description
ERP5 provided with standalone package - playbook.
%install
mkdir -p %{buildroot}/opt/
cp -a /opt/slapos.playbook %{buildroot}/opt/
%files
/opt/slapos.playbook
\ No newline at end of file
%include common.inc
Name: erp5-standalone
Summary: ERP5 standalone
Requires: erp5-standalone-erp5-1 erp5-standalone-erp5-2
Requires: erp5-standalone-erp5-3 erp5-standalone-erp5-4
Requires: erp5-standalone-erp5-5
Requires: erp5-standalone-frontend erp5-standalone-playbook
Requires: ansible
%description
ERP5 provided with standalone package - metapackage.
%files
%post
echo "# SlapOS ansible offline from erp5-standalone rpm" > /etc/ansible/hosts
echo "[targets]" >> /etc/ansible/hosts
echo "127.0.0.1 ansible_connection=local slapos_ansible_offline=true" >> /etc/ansible/hosts
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment