Verified Commit f58d6959 authored by Aleksey Shirokih's avatar Aleksey Shirokih
Browse files

initial

parents
Dummy role to place custom code to
\ No newline at end of file
custom_repo: ""
custom_path: "{{ noc_root }}/../noc_custom"
---
forms:
custom:
description: >
<strong>Service type</strong>: Not a service <br/>
<strong>Short description</strong>: Example role to fetch custom data <br/>
<strong>Long description</strong>: Set location to fetch custom repo from<br/>
<strong>Scale Recommendations</strong>: None<br/>
<strong>docs</strong>: <a href=http://docs.getnoc.com/en/latest/hacking/ target=_blank>Hacking Noc</a><br/>
<strong>Placement constraint</strong>: Will be placed on each node<br/>
repo:
label: "Custom repo localtion"
type: str
version:
label: "Custom repo version"
type: str
default: master
path:
label: "Place custom code to"
type: str
default: /opt/noc_custom
services:
custom:
level: system
category: config
depends:
- noc
- name: Install NOC
hosts: svc-noc-exec
become: yes
any_errors_fatal: false
gather_facts: True
tags:
- node
- noc
vars_files:
- "../../vars/main.yml"
- "../../vars/{{ ansible_distribution }}.yml"
roles:
- role: custom
\ No newline at end of file
- name: Pull NOC custom
git:
repo: "{{custom_repo}}"
dest: "{{custom_path}}"
version: "{{custom_version}}"
force: yes
clone: yes
diff: False
when:
- custom_repo is defined
- custom_repo | length > 2
environment:
https_proxy: "{{http_proxy}}"
tags:
- get_source
- custom
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment