Initial parity cookbook
Supports installing multiple instances of Parity on the same machine, running on different ports Refs #15
This commit is contained in:
56
site-cookbooks/kosmos-parity/recipes/default.rb
Normal file
56
site-cookbooks/kosmos-parity/recipes/default.rb
Normal file
@@ -0,0 +1,56 @@
|
||||
#
|
||||
# Cookbook Name:: kosmos-parity
|
||||
# Recipe:: default
|
||||
#
|
||||
# Copyright 2017, Kosmos
|
||||
#
|
||||
# All rights reserved - Do Not Redistribute
|
||||
#
|
||||
|
||||
group "parity" do
|
||||
gid 72748
|
||||
end
|
||||
|
||||
user "parity" do
|
||||
system true
|
||||
manage_home true
|
||||
comment "parity user"
|
||||
uid 72748
|
||||
gid 72748
|
||||
end
|
||||
|
||||
parity_version = "1.6.6"
|
||||
parity_package_path = "#{Chef::Config[:file_cache_path]}/parity_#{parity_version}_amd64.deb"
|
||||
remote_file parity_package_path do
|
||||
source "https://d1h4xl4cr1h0mo.cloudfront.net/v#{parity_version}/x86_64-unknown-linux-gnu/parity_#{parity_version}_amd64.deb"
|
||||
mode 0750
|
||||
notifies :install, "dpkg_package[parity]", :immediately
|
||||
end
|
||||
|
||||
dpkg_package "parity" do
|
||||
source parity_package_path
|
||||
end
|
||||
|
||||
parity_node "dev" do
|
||||
config chain: "dev",
|
||||
network_port: 30303,
|
||||
json_rpc_port: 8545,
|
||||
dapps_port: 8090,
|
||||
ui_port: 8180
|
||||
end
|
||||
|
||||
parity_node "testnet" do
|
||||
config chain: "ropsten",
|
||||
network_port: 30304,
|
||||
json_rpc_port: 8546,
|
||||
dapps_port: 8091,
|
||||
ui_port: 8181
|
||||
end
|
||||
|
||||
parity_node "mainnet" do
|
||||
config chain: "homestead",
|
||||
network_port: 30305,
|
||||
json_rpc_port: 8547,
|
||||
dapps_port: 8092,
|
||||
ui_port: 8182
|
||||
end
|
||||
Reference in New Issue
Block a user