Graduating pump.io to working status
This commit is contained in:
parent
320cebe3ff
commit
5f400b088d
232
beaglebone.txt
232
beaglebone.txt
|
@ -5390,6 +5390,133 @@ So, you're now microblogging on the open web, with no companies in the middle.
|
|||
|
||||
When following other GNU Social users enter the URL of your profile. For example, https://mygnusocialdomain/myusername
|
||||
|
||||
*** pump.io
|
||||
|
||||
For a pump.io site you will need a separate domain/subdomain, so see [[Setting up a web site]] for details of how to create an Apache configuration for your site. If you're using freedns then you will need to create a new subdomain.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
apt-get update && apt-get install redis-server nodejs-legacy graphicsmagick git-core screen
|
||||
cd /opt
|
||||
git clone https://github.com/e14n/pump.io.git
|
||||
cd /opt/pump.io
|
||||
npm install
|
||||
npm install databank-redis
|
||||
#+END_SRC
|
||||
|
||||
Edit the configuration file.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
emacs /etc/pump.io.json
|
||||
#+END_SRC
|
||||
|
||||
Add the following, replacing /mypumpiodomainname.com/ with your domain name.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
{
|
||||
"driver": "redis",
|
||||
"params": {"host":"localhost","port":6379},
|
||||
"secret": "A long random string",
|
||||
"noweb": false,
|
||||
"site": "Name of my pump.io site",
|
||||
"owner": "My name or organisation",
|
||||
"ownerURL": "https://mypumpiodomainname.com/",
|
||||
"port": 7270,
|
||||
"urlPort": 443,
|
||||
"hostname": "mypumpiodomainname.com",
|
||||
"address": "localhost",
|
||||
"nologger": false,
|
||||
"serverUser": "pumpio",
|
||||
"key": "/var/local/pump.io/keys/mypumpiodomainname.com.key",
|
||||
"cert": "/var/local/pump.io/keys/mypumpiodomainname.com.crt",
|
||||
"uploaddir": "/var/local/pump.io/uploads",
|
||||
"debugClient": false,
|
||||
"firehose": "ofirehose.example",
|
||||
"logfile": "/var/local/pump.io/pump.io.log",
|
||||
"disableRegistration": false
|
||||
}
|
||||
#+END_SRC
|
||||
|
||||
Save and exit.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
export HOSTNAME=mypumpiodomainname.com
|
||||
mkdir /var/local/pump.io
|
||||
mkdir /var/local/pump.io/uploads
|
||||
mkdir /var/local/pump.io/keys
|
||||
cp /etc/ssl/private/$HOSTNAME.key /var/local/pump.io/keys
|
||||
cp /etc/ssl/certs/$HOSTNAME.crt /var/local/pump.io/keys
|
||||
useradd -s /bin/bash -d /var/local/pump.io pumpio
|
||||
chown -R pumpio:pumpio /var/local/pump.io
|
||||
chmod 400 /var/local/pump.io/keys/*
|
||||
mkdir /tmp/apache2
|
||||
cd /tmp/apache2
|
||||
apt-get build-dep apache2
|
||||
apt-get install autoconf
|
||||
apt-get source apache2
|
||||
cd apache2-*
|
||||
wget http://freedombone.uk.to/apache-2.2-wstunnel.patch
|
||||
sha256sum apache-2.2-wstunnel.patch
|
||||
cfc4866da2688a8eb76e0300cf16b52539ef4e525053a3851d4b6bba9a77e439
|
||||
|
||||
patch -p1 -i apache-2.2-wstunnel.patch
|
||||
autoconf
|
||||
./configure --enable-so --enable-proxy=shared --enable-proxy-wstunnel=shared
|
||||
make
|
||||
cp modules/proxy/.libs/mod_proxy_wstunnel.so /usr/lib/apache2/modules/
|
||||
cd /etc/apache2/mods-enabled
|
||||
ln -s /usr/lib/apache2/modules/mod_proxy_wstunnel.so ../mods-available/proxy_wstunnel.load
|
||||
#+END_SRC
|
||||
|
||||
Within the section of your Apache site configuration:
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
emacs /etc/apache2/sites-available/mypumpiodomainname.com
|
||||
#+END_SRC
|
||||
|
||||
Add the following in the section which begins with *<VirtualHost *:443>*.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
LoadModule proxy_wstunnel_module /usr/lib/apache2/modules/mod_proxy_wstunnel.so
|
||||
|
||||
<Location /main/realtime/sockjs>
|
||||
ProxyPass wss://localhost/main/realtime/sockjs
|
||||
ProxyPassReverse wss://localhost/main/realtime/sockjs
|
||||
</Location>
|
||||
|
||||
# <LocationMatch ".*\.(jpg|png|gif)$">
|
||||
# CacheEnable disk
|
||||
# </LocationMatch>
|
||||
|
||||
ProxyVia On
|
||||
ProxyPreserveHost On
|
||||
SSLProxyEngine On
|
||||
|
||||
ProxyPass / https://localhost:7270/
|
||||
ProxyPassReverse / https://localhost:7270/
|
||||
#+END_SRC
|
||||
|
||||
Save and exit.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
a2enmod cache
|
||||
a2enmod disk_cache
|
||||
apachectl configtest
|
||||
service apache2 restart
|
||||
#+END_SRC
|
||||
|
||||
Now you can run the pump.io server:
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
npm install forever -g
|
||||
su - pumpio -c 'cd /opt/pump.io && forever ./bin/pump &'
|
||||
#+END_SRC
|
||||
|
||||
Now visit your pump.io site by navigating to:
|
||||
|
||||
https://mypumpiodomainname.com
|
||||
|
||||
and adding a new user. If you wish this to be a single user node not open to the general public (including spammers and sockpuppets) then edit */etc/pump.io.json* and set *disableRegistration* to *true*. After making that change reboot the BBB by typing "reboot".
|
||||
|
||||
** Install Tripwire
|
||||
|
||||
#+BEGIN_VERSE
|
||||
|
@ -6098,111 +6225,6 @@ Within a browser open https://mydomainname.com:8888
|
|||
|
||||
See documentation in /usr/share/doc/kune/INSTALL.gz
|
||||
|
||||
** pump.io
|
||||
|
||||
For a pump.io site you will need a separate domain/subdomain, so see [[Setting up a web site]] for details of how to create an Apache configuration for your site. If you're using freedns then you will need to create a new subdomain.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
apt-get update && apt-get install redis-server nodejs-legacy graphicsmagick git-core screen
|
||||
cd /opt
|
||||
git clone https://github.com/e14n/pump.io.git
|
||||
cd /opt/pump.io
|
||||
npm install
|
||||
#+END_SRC
|
||||
|
||||
Edit the configuration file.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
emacs /etc/pump.io.json
|
||||
#+END_SRC
|
||||
|
||||
Add the following, replacing /mypumpiodomainname.com/ with your domain name.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
{
|
||||
"driver": "redis",
|
||||
"params": {"host":"localhost","port":6379},
|
||||
"secret": "A long random string",
|
||||
"noweb": false,
|
||||
"site": "Name of my pump.io site",
|
||||
"owner": "My name or organisation",
|
||||
"ownerURL": "https://mypumpiodomainname.com/",
|
||||
"port": 443,
|
||||
"hostname": "mypumpiodomainname.com",
|
||||
"address": "localhost",
|
||||
"nologger": false,
|
||||
"serverUser": "pumpio",
|
||||
"key": "/etc/ssl/private/mypumpiodomainname.com.key",
|
||||
"cert": "/etc/ssl/certs/mypumpiodomainname.com.crt",
|
||||
"uploaddir": "/var/local/pump.io/uploads",
|
||||
"debugClient": false,
|
||||
"firehose": "ofirehose.example",
|
||||
"logfile": "/var/log/pump.io.log",
|
||||
"disableRegistration": false
|
||||
}
|
||||
#+END_SRC
|
||||
|
||||
Save and exit.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
mkdir /var/local/pump.io
|
||||
mkdir /var/local/pump.io/uploads
|
||||
useradd -s /bin/bash -d /var/local/pump.io pumpio
|
||||
chown -R pumpio:pumpio /var/local/pump.io
|
||||
#+END_SRC
|
||||
|
||||
Within the section of your Apache site configuration (in /etc/apache2/sites-available/mypumpiodomainname.com) add the following in the section which begins with *<VirtualHost *:443>*.
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
mkdir /tmp/apache2
|
||||
cd /tmp/apache2
|
||||
apt-get build-dep apache2
|
||||
apt-get install autoconf
|
||||
apt-get source apache2
|
||||
cd apache2-*
|
||||
wget http://freedombone.uk.to/apache-2.2.24-wstunnel.patch
|
||||
sha256sum apache-2.2.24-wstunnel.patch
|
||||
7cfe86bb31c6674a316a6b1d8ba48cc2adaf9200348e3c95c29654f387c85cc2
|
||||
|
||||
patch -p1 -i apache-2.2.24-wstunnel.patch
|
||||
autoconf
|
||||
./configure --enable-so --enable-proxy=shared --enable-proxy-wstunnel=shared
|
||||
make
|
||||
cp modules/proxy/.libs/mod_proxy_wstunnel.so /usr/lib/apache2/modules/
|
||||
cd /etc/apache2/mods-enabled
|
||||
ln -s ../mods-available/proxy_wstunnel.load
|
||||
#+END_SRC
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
LoadModule proxy_wstunnel_module /usr/lib/apache2/modules/mod_proxy_wstunnel.so
|
||||
|
||||
<Location /main/realtime/sockjs>
|
||||
ProxyPass wss://localhost/main/realtime/sockjs
|
||||
ProxyPassReverse wss://localhost/main/realtime/sockjs
|
||||
</Location>
|
||||
|
||||
<LocationMatch ".*\.(jpg|png|gif)$">
|
||||
CacheEnable disk
|
||||
</LocationMatch>
|
||||
|
||||
ProxyPreserveHost On
|
||||
|
||||
ProxyPass / https://192.168.x.y/
|
||||
ProxyPassReverse / https://192.168.x.y/
|
||||
#+END_SRC
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
apachectl confgitest
|
||||
service apache2 restart
|
||||
#+END_SRC
|
||||
|
||||
|
||||
|
||||
#+BEGIN_SRC: bash
|
||||
./opt/pump.io/bin/pump
|
||||
npm install forever -g
|
||||
#+END_SRC
|
||||
|
||||
* Related projects
|
||||
|
||||
* [[https://freedomboxfoundation.org/][Freedombox]]
|
||||
|
|
Loading…
Reference in New Issue