Skip to content

Commit be6fc64

Browse files
committed
added plv8
1 parent f72bf25 commit be6fc64

File tree

2 files changed

+18
-9
lines changed

2 files changed

+18
-9
lines changed

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ http://armviz.io/#/?load=https%3A%2F%2Fraw.githubusercontent.com%2Fhellotech%2Fa
77

88
# Azure Patroni Deployment
99

10-
One click deployment of a Highly-Available PostgreSQL Cluster on Azure. With automated replication, server management and leader election. This project contains a modified deployment version of Haufe's [blog post](http://dev.haufe.com/PostgreSQL-Cluster-Azure/).
10+
This one click deployment of a Highly-Available PostgreSQL Cluster on Azure has automated replication, server management and leader election. This project contains a modified deployment version of Haufe's [blog post](http://dev.haufe.com/PostgreSQL-Cluster-Azure/).
1111

12-
This azure template generates two sets of machines both running Ubuntu 16.04 LTS. The first set of three machines are used to run the distributed configuration store [ZooKeeper](https://zookeeper.apache.org/), while the second set is running PostgreSQL 9.6 together with [Patroni](https://github.com/zalando/patroni) providing a high-availability customizable PostgreSQL cluster deployment.
12+
This Azure template generates two sets of machines both running Ubuntu 16.04 LTS. The first set of three machines are used to run the distributed configuration store [ZooKeeper](https://zookeeper.apache.org/), while the second set is running PostgreSQL 9.6 together with [Patroni](https://github.com/zalando/patroni) providing a high-availability customizable PostgreSQL cluster deployment.
1313

1414
# Parameters
1515

@@ -26,11 +26,11 @@ This template provides the following parameters, so you can customize your deplo
2626

2727
* lbType: Whether you want to create an external or internal load balancer. If set to internal the load balancer will only be accessible from inside the virtual network. Default("internal")
2828

29-
* vnetName: If newVnet is set to yet the this will be name of the created vnet otherwise this is the name of already existing vnet to which the deployment will be associated.
29+
* vnetName: If newVnet is set to yes, this will be name of the created vnet. Otherwise, this is the name of already existing vnet to which the deployment will be associated.
3030

31-
* zookeeperNetName: If newVnet is set to yes the this will be name of the created subnet for the zookeeper machines, otherwise this is the name of already existing subnet that will contain the zookeeper vm's.
31+
* zookeeperNetName: If newVnet is set to yes, this will be name of the created subnet for the zookeeper machines, otherwise this is the name of already existing subnet that will contain the zookeeper vm's.
3232

33-
* postgresNetName: If newVnet is set to yes the this will be name of the created subnet for the postgres machines, otherwise this is the name of already existing subnet that will contain the postgres vm's.
33+
* postgresNetName: If newVnet is set to yes, this will be name of the created subnet for the postgres machines, otherwise this is the name of already existing subnet that will contain the postgres vm's.
3434

3535
* zookeeperVMSize: The size of zookeeper vms.
3636

@@ -48,13 +48,13 @@ This template provides the following parameters, so you can customize your deplo
4848
# Scripts
4949

5050
### Zookeeper
51-
The creation of the zookeeper instances is handled by the [zookeeper_startup.sh](https://github.com/HelloTech/azure_patroni/blob/custom_deploy/zookeeper_startup.sh) script. If you would like to make any changes to what is installed on those vm's that's the file you should modify.
51+
The creation of the zookeeper instances is handled by the [zookeeper_startup.sh](https://github.com/HelloTech/azure_patroni/blob/custom_deploy/zookeeper_startup.sh) script. If you would like to make any changes to what is installed on those vm's modify this file.
5252

5353
### Mounts
5454
The mounting of the data ssds is handled by the [autopart.sh](https://github.com/HelloTech/azure_patroni/blob/custom_deploy/autopart.sh) script.
5555

5656
### Postgres
57-
The creation of the postgres instances is handles by the [postgres_startup.sh](https://github.com/HelloTech/azure_patroni/blob/custom_deploy/postgres_startup.sh) script. If you would like to make any changes to what is installed on those vm's that's the file you should modify.
57+
The creation of the postgres instance is handles by the [postgres_startup.sh](https://github.com/HelloTech/azure_patroni/blob/custom_deploy/postgres_startup.sh) script. If you would like to make any changes to what is installed on those vm's modify that script.
5858

5959
# License
6060

postgres_startup.sh

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,10 +79,19 @@ echo "pip python-dateutil exited with: $?"
7979
#sudo touch /usr/sbin/policy-rc.d
8080
#sudo chmod 777 /usr/sbin/policy-rc.d
8181
#echo exit 101 > /usr/sbin/policy-rc.d
82-
sudo apt-get --assume-yes --force-yes -qq install postgresql postgresql-contrib
83-
echo "apt-get postgresql postgresql-contrib exited with: $?"
82+
sudo apt-get --assume-yes --force-yes -qq install postgresql postgresql-contrib postgresql-server-dev-9.6
83+
echo "apt-get postgresql postgresql-server-dev-9.6 postgresql-contrib exited with: $?"
8484
export PATH=/usr/lib/postgresql/9.6/bin:$PATH
8585

86+
#install plv8
87+
wget https://github.com/plv8/plv8/archive/v2.0.0.tar.gz
88+
tar -xvzf v2.0.0.tar.gz
89+
cd plv8-2.0.0
90+
make static
91+
sudo cp plv8.so /usr/lib/postgresql/9.6/lib/
92+
sudo cp plv8.control /usr/share/postgresql/9.6/extension/
93+
sudo cp plv8--2.0.0.sql /usr/share/postgresql/9.6/extension/
94+
8695
# download patroni
8796
sudo apt-get --assume-yes -qq install unzip
8897
echo "apt-get unzip exited with: $0"

0 commit comments

Comments
 (0)