-
Notifications
You must be signed in to change notification settings - Fork 87
feat(pkg): separate components, use requisites and add clean
states
#48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
c21f82b
6e7141b
422c7ac
2838bc9
a218e91
d957055
4443518
726fcab
bf1039c
b7356b0
2cd82e5
6690ee6
007159a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# -*- coding: utf-8 -*- | ||
# vim: ft=sls | ||
|
||
include: | ||
- .service.clean | ||
- .config.clean | ||
- .package.clean |
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# -*- coding: utf-8 -*- | ||
# vim: ft=sls | ||
|
||
{#- Get the `tplroot` from `tpldir` #} | ||
{%- set tplroot = tpldir.split('/')[0] %} | ||
{%- set sls_service_clean = tplroot ~ '.service.clean' %} | ||
{%- from tplroot ~ "/map.jinja" import template with context %} | ||
{%- from tplroot ~ "/macros.jinja" import files_switch with context %} | ||
|
||
include: | ||
- {{ sls_service_clean }} | ||
|
||
template-config-clean-file-absent: | ||
file.absent: | ||
- name: {{ template.config }} | ||
- require: | ||
- sls: {{ sls_service_clean }} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# -*- coding: utf-8 -*- | ||
# vim: ft=sls | ||
|
||
{#- Get the `tplroot` from `tpldir` #} | ||
{%- set tplroot = tpldir.split('/')[0] %} | ||
{%- set sls_package_install = tplroot ~ '.package.install' %} | ||
{%- from tplroot ~ "/map.jinja" import template with context %} | ||
{%- from tplroot ~ "/macros.jinja" import files_switch with context %} | ||
|
||
include: | ||
- {{ sls_package_install }} | ||
|
||
template-config-file-file-managed: | ||
file.managed: | ||
- name: {{ template.config }} | ||
- source: {{ files_switch( | ||
salt['config.get']( | ||
tplroot ~ ':tofs:files:template-config', | ||
['example.tmpl', 'example.tmpl.jinja'] | ||
) | ||
) }} | ||
- mode: 644 | ||
- user: root | ||
- group: root | ||
- template: jinja | ||
- require: | ||
- sls: {{ sls_package_install }} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# -*- coding: utf-8 -*- | ||
myii marked this conversation as resolved.
Show resolved
Hide resolved
|
||
# vim: ft=sls | ||
|
||
include: | ||
- .file |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,6 @@ | |
# vim: ft=sls | ||
|
||
include: | ||
- template.install | ||
- template.config | ||
- template.service | ||
- .package | ||
- .config | ||
- .service |
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# -*- coding: utf-8 -*- | ||
# vim: ft=sls | ||
|
||
{#- Get the `tplroot` from `tpldir` #} | ||
{%- set tplroot = tpldir.split('/')[0] %} | ||
{%- set sls_config_clean = tplroot ~ '.config.clean' %} | ||
{%- from tplroot ~ "/map.jinja" import template with context %} | ||
|
||
include: | ||
- {{ sls_config_clean }} | ||
|
||
template-package-clean-pkg-removed: | ||
pkg.removed: | ||
- name: {{ template.pkg }} | ||
- require: | ||
- sls: {{ sls_config_clean }} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# -*- coding: utf-8 -*- | ||
# vim: ft=sls | ||
|
||
include: | ||
- .install |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# -*- coding: utf-8 -*- | ||
# vim: ft=sls | ||
|
||
{#- Get the `tplroot` from `tpldir` #} | ||
{%- set tplroot = tpldir.split('/')[0] %} | ||
{%- from tplroot ~ "/map.jinja" import template with context %} | ||
|
||
template-package-install-pkg-installed: | ||
pkg.installed: | ||
- name: {{ template.pkg }} |
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# -*- coding: utf-8 -*- | ||
# vim: ft=sls | ||
|
||
{#- Get the `tplroot` from `tpldir` #} | ||
{%- set tplroot = tpldir.split('/')[0] %} | ||
{%- from tplroot ~ "/map.jinja" import template with context %} | ||
|
||
template-service-clean-service-dead: | ||
service.dead: | ||
- name: {{ template.service.name }} | ||
- enable: False |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# -*- coding: utf-8 -*- | ||
# vim: ft=sls | ||
|
||
include: | ||
- .running | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Again There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Here I see |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# -*- coding: utf-8 -*- | ||
# vim: ft=sls | ||
|
||
{#- Get the `tplroot` from `tpldir` #} | ||
{%- set tplroot = tpldir.split('/')[0] %} | ||
{%- set sls_config_file = tplroot ~ '.config.file' %} | ||
{%- from tplroot ~ "/map.jinja" import template with context %} | ||
|
||
include: | ||
- {{ sls_config_file }} | ||
|
||
template-service-running-service-running: | ||
service.running: | ||
- name: {{ template.service.name }} | ||
- enable: True | ||
- require: | ||
- sls: {{ sls_config_file }} |
Uh oh!
There was an error while loading. Please reload this page.