Skip to content

Commit

Permalink
fixes #37524 - feat: enable ansible variable events
Browse files Browse the repository at this point in the history
Signed-off-by: gardar <[email protected]>
  • Loading branch information
gardar authored and nofaralfasi committed Aug 28, 2024
1 parent 174db1b commit cacd476
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/models/ansible_variable.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

# Represents the variables used in Ansible to parameterize playbooks
class AnsibleVariable < LookupKey
include Foreman::ObservableModel

belongs_to :ansible_role, :inverse_of => :ansible_variables
validates :ansible_role_id, :presence => true
before_validation :cast_default_value, :if => :override?
Expand All @@ -11,6 +13,8 @@ class AnsibleVariable < LookupKey
scoped_search :relation => :ansible_role, :on => :name,
:complete_value => true, :rename => :ansible_role

set_crud_hooks :ansible_variable

def ansible?
true
end
Expand Down

0 comments on commit cacd476

Please sign in to comment.