Backup the parity keys

This commit is contained in:
Greg Karékinian 2017-05-08 17:42:29 +02:00
parent 2e0730e3e8
commit e871095bb4
4 changed files with 7 additions and 3 deletions

View File

@ -12,3 +12,4 @@ depends 'ark'
depends 'build-essential'
depends 'kosmos-nginx'
depends 'firewall'
depends 'backup'

View File

@ -21,3 +21,5 @@ end
dpkg_package "parity" do
source parity_package_path
end
include_recipe "kosmos-parity::backup"

View File

@ -25,3 +25,5 @@ dpkg_package "parity" do
source parity_package_path
version "#{parity_version}-#{package_timestamp}"
end
include_recipe "kosmos-parity::backup"

View File

@ -10,7 +10,7 @@ property :rpc_proxy_port, Integer
action :enable do
node_name = name
parity_service = "parity_#{node_name}"
base_path = "#{node['kosmos-parity']['home_path']}/.local/share/io.parity.ethereum/#{name}"
base_path = "#{node['kosmos-parity']['home_path']}/.local/share/io.parity.ethereum/#{node_name}"
config_path = "#{base_path}/config.toml"
config[:parity][:base_path] = base_path
@ -31,8 +31,7 @@ action :enable do
end
end
node_path = "#{node['kosmos-parity']['home_path']}/.local/share/io.parity.ethereum/#{node_name}"
password_path = "#{node_path}/password"
password_path = "#{base_path}/password"
file password_path do
content password