Files

27 lines
460 B
Ruby
Raw Permalink Normal View History

2026-06-12 15:40:12 -04:00
# encoding: utf-8
class Machine < ActiveRecord::Base
# attr_accessible :title, :body
# validates :title, :presence => true
# validates :body, :presence => true
has_many :services
belongs_to :local_network
# scope :published, -> { order("created_at DESC") }
# def tailscale_ip
# tailscale_ip
# end
def local_domain
"#{domain}.#{local_network.tld}"
end
def local_ip
"#{local_network.subnet}.#{local_ip_octet}"
end
end