Advertisement
Guest User

Untitled

a guest
Apr 28th, 2019
360
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.90 KB | None | 0 0
  1.  
  2.  
  3. plex user sensor:
  4.  
  5. - platform: template
  6. sensors:
  7. plex_users:
  8. value_template: >-
  9. {% for attr in states.sensor.plex.attributes %}
  10. {%- if not attr=="friendly_name" and not attr=="unit_of_measurement" and not attr=="icon" -%}
  11. {{attr}} is watching {{states.sensor.plex.attributes [attr]}}
  12. {%- endif %}
  13. {%- endfor -%}
  14.  
  15.  
  16.  
  17. plex lovelace card:
  18.  
  19. - type: custom:vertical-stack-in-card
  20. title: Plex
  21. cards:
  22. - type: custom:mini-graph-card
  23. entities:
  24. - sensor.plex
  25. height: 50
  26. font_size: 60
  27. show:
  28. labels: false
  29. name: false
  30. icon: false
  31. color_thresholds:
  32. - value: 1
  33. color: "#64f211"
  34. - value: 2
  35. color: "#f1f111"
  36. - value: 3
  37. color: "#c0392b"
  38. - value: 4
  39. color: "#f09b11"
  40. - value: 5
  41. color: "#ef5710"
  42. - value: 6
  43. color: "#ef0f0f"
  44. - type: conditional
  45. conditions:
  46. - entity: sensor.plex
  47. state_not: '0'
  48. card:
  49. type: custom:useful-markdown-card
  50. content: >
  51. [[ sensor.plex_users.state ]]
  52.  
  53.  
  54.  
  55. pi-hole switch:
  56.  
  57. # PiHole
  58. - platform: command_line
  59. switches:
  60. pihole_switch:
  61. command_on: "curl -X GET 'http://XXX.XXX.X.XX:XXXX/admin/api.php?enable&auth=KEY'"
  62. command_off: "curl -X GET 'http://XXX.XXX.X.XX:XXXX/admin/api.php?disable=3600&auth=KEY'"
  63. command_state: "curl -X GET 'XXX.XXX.X.XX:XXXX/admin/api.php?status&auth=KEY'"
  64. value_template: "{{ value_json.status == 'enabled' }}"
  65.  
  66.  
  67.  
  68. pi-hole lovelace card:
  69.  
  70. - type: custom:vertical-stack-in-card
  71. title: Pi-Hole
  72. cards:
  73. - type: custom:mini-graph-card
  74. entities:
  75. - sensor.pi_hole_ads_blocked_today
  76. height: 50
  77. font_size: 60
  78. show:
  79. name: true
  80. state: true
  81. icon: false
  82. - type: glance
  83. show_name: false
  84. show_state: false
  85. columns: 2
  86. entities:
  87. - entity: switch.pihole_switch
  88. icon: mdi:cancel
  89. tap_action:
  90. action: toggle
  91. - entity: switch.pausepihole
  92. icon: mdi:pause
  93. tap_action:
  94. action: toggle
  95.  
  96.  
  97.  
  98. docker lovelace card:
  99.  
  100. - type: custom:vertical-stack-in-card
  101. title: Docker
  102. cards:
  103. - type: glance
  104. show_name: true
  105. show_state: false
  106. columns: 3
  107. entities:
  108. - entity: switch.piholedocker
  109. name: Pi-Hole
  110. icon: mdi:chart-pie
  111. tap_action:
  112. action: more-info
  113. - entity: switch.mariadbdocker
  114. name: MariaDB
  115. icon: mdi:database
  116. tap_action:
  117. action: more-info
  118. - entity: switch.mosquittodocker
  119. name: Mosquitto
  120. icon: mdi:message
  121. tap_action:
  122. action: more-info
  123. - entity: switch.dockermonitor
  124. name: Monitor
  125. icon: mdi:monitor
  126. tap_action:
  127. action: more-info
  128. - entity: switch.portainerdocker
  129. name: Portainer
  130. icon: mdi:file-document-box-multiple-outline
  131. tap_action:
  132. action: more-info
  133. - entity: switch.letsencryptdocker
  134. name: Lets Encrypt
  135. icon: mdi:lock-plus
  136. tap_action:
  137. action: more-info
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement