Skip to content

Commit

Permalink
minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
randywallace committed Sep 6, 2013
1 parent 6ebeb6f commit f8dcc8c
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions app/models/container.rb
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,11 @@ def ip

def users
users = []
File.open(File.join(root_path, 'rootfs', 'etc', 'passwd')).each_line do |line|
users << line.split(':')
f = File.join(root_path, 'rootfs', 'etc', 'passwd')
if File.exists?(f)
File.open(f).each_line do |line|
users << line.split(':')
end
end
users
end
Expand Down

0 comments on commit f8dcc8c

Please sign in to comment.