Skip to content

Commit

Permalink
refactor: lint ref from master to main (#13)
Browse files Browse the repository at this point in the history
* refactor: lint ref from master to main
* feat: adding multicast configuration
  • Loading branch information
mabunixda authored Jun 29, 2022
1 parent 19872de commit 687bca0
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 14 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Lint Ansible Playbook
uses: ansible/ansible-lint-action@master
uses: ansible/ansible-lint-action@main
continue-on-error: true

release:
runs-on: ubuntu-latest
needs: build
Expand Down
20 changes: 10 additions & 10 deletions defaults/main.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
---

nodeexporter_enabled: yes
frr_enabled: no
rsyncd_enabled: no
openvpn_enabled: no
zerotier_enabled: no
cloudflare_enabled: no
multicast_enabled: no
force_external_dns: no
falsedeexporter_enabled: true
frr_enabled: false
rsyncd_enabled: false
openvpn_enabled: false
zerotier_enabled: false
cloudflare_enabled: false
multicast_enabled: false
force_external_dns: false

multicast_interfaces: ""

Expand All @@ -24,7 +24,7 @@ java_certificate_import: "java -jar /usr/lib/unifi/lib/ace.jar import_key_cert"
udm_onboot_version: 1.0.5
udm_onboot_download_uri: "https://github.com/unifi-utilities/unifios-utilities/releases/download/{{ udm_onboot_version }}/udm-boot_{{ udm_onboot_version }}_all.deb"

install_kernel_tools: no
udm_kernel_tools_autoboot: yes
install_kernel_tools: false
udm_kernel_tools_autoboot: true
udm_kernel_tool_version: 1.1.2
udm_kernel_tool_download_uri: "https://github.com/fabianishere/udm-kernel-tools/releases/download/v{{ udm_kernel_tool_version }}/udm-kernel-tools_{{ udm_kernel_tool_version }}_arm64.deb"
4 changes: 2 additions & 2 deletions tasks/certificate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@

- name: transfer certificate file
delegate_to: localhost
become: no
become: false
command:
cmd: scp "{{ certificate }}" {{ inventory_hostname }}:"{{ unifi_certificate_path }}/unifi-core.crt"

- name: transfer certificate key
delegate_to: localhost
become: no
become: false
command:
cmd: scp "{{ certificate_key }}" {{ inventory_hostname }}:{{ unifi_certificate_path }}/unifi-core.key

Expand Down
2 changes: 1 addition & 1 deletion tasks/onboot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

- name: onboot - deploy custom configurations
delegate_to: localhost
become: no
become: false
with_items:
- { file: "files/00-onboot-sshkeys.sh", enabled: yes }
- { file: "files/05-onboot-container.sh", enabled: yes }
Expand Down
19 changes: 19 additions & 0 deletions templates/container-multicast.sh.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#!/usr/bin/env sh

DEBUG=${DEBUG:--d}
CONTAINER_NAME="mrelay"
OPTS="--noMDNS"
INTERFACES="${multicast_interfaces}"

if podman container exists ${CONTAINER_NAME}; then
podman start ${CONTAINER_NAME}
else
podman run--name "${CONTAINER_NAME}" \
--restart always \
--network=host \
-e OPTS="${OPTS}" \
-e INTERFACES="${INTERFACES}" \
$DEBUG \
docker.io/scyto/multicast-relay
fi

0 comments on commit 687bca0

Please sign in to comment.