Fixed code styling
This commit is contained in:
@@ -17,5 +17,5 @@ node.default['ipfs']['config']['swarm']['addr_filter'] = [
|
||||
"/ip4/198.18.0.0/ipcidr/15",
|
||||
"/ip4/198.51.100.0/ipcidr/24",
|
||||
"/ip4/203.0.113.0/ipcidr/24",
|
||||
"/ip4/240.0.0.0/ipcidr/4"
|
||||
"/ip4/240.0.0.0/ipcidr/4",
|
||||
]
|
||||
|
||||
@@ -6,6 +6,6 @@ description 'Installs/Configures ipfs'
|
||||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
|
||||
version '0.1.0'
|
||||
|
||||
supports ['ubuntu', 'debian']
|
||||
supports %w(ubuntu debian)
|
||||
|
||||
depends 'ark'
|
||||
|
||||
@@ -34,7 +34,7 @@ execute "ipfs init --empty-repo" do
|
||||
end
|
||||
|
||||
if platform?('ubuntu') && node[:platform_version].to_f < 15.04 ||
|
||||
platform?('debian') && node['platform_version'].to_f < 8
|
||||
platform?('debian') && node['platform_version'].to_f < 8
|
||||
template "ipfs.initd.service.erb" do
|
||||
path "/etc/init.d/ipfs"
|
||||
source 'ipfs.initd.service.erb'
|
||||
|
||||
@@ -15,8 +15,9 @@ action :create do
|
||||
not_if do
|
||||
require 'json'
|
||||
require 'mixlib/shellout'
|
||||
cmd = Mixlib::ShellOut.new("ipfs", "config", key, user: 'ipfs',
|
||||
env: {"IPFS_PATH" => "/home/ipfs/.ipfs"})
|
||||
cmd = Mixlib::ShellOut.new("ipfs", "config", key,
|
||||
user: 'ipfs',
|
||||
env: { "IPFS_PATH" => "/home/ipfs/.ipfs" })
|
||||
cmd.run_command
|
||||
begin
|
||||
JSON.parse(cmd.stdout) == value
|
||||
|
||||
@@ -4,7 +4,6 @@ require 'serverspec'
|
||||
set :backend, :exec
|
||||
|
||||
describe "IPFS" do
|
||||
|
||||
# It is in the PATH
|
||||
describe command("which ipfs") do
|
||||
its(:exit_status) { should eq 0 }
|
||||
@@ -22,5 +21,4 @@ describe "IPFS" do
|
||||
expect(service("ipfs")).to be_running
|
||||
expect(service("ipfs")).to be_enabled
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user