Compare commits
3 Commits
dd6e9ddf63
...
d4661682b5
| Author | SHA1 | Date | |
|---|---|---|---|
| d4661682b5 | |||
| 0256e66d71 | |||
| fbd335a39b |
@@ -4,3 +4,4 @@
|
||||
roles:
|
||||
- common
|
||||
- unbound
|
||||
- netbird_peer
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
netbird_version: "0.68.3"
|
||||
netbird_sha256: "a3ba352f2b2bfbcd1bf157257b3b1fbe4c9d21dee2a7cb15e9c36b2a092563d9 "
|
||||
|
||||
private_domains:
|
||||
- name: jthan.io
|
||||
records:
|
||||
|
||||
34
ansible/roles/netbird_peer/tasks/main.yaml
Normal file
34
ansible/roles/netbird_peer/tasks/main.yaml
Normal file
@@ -0,0 +1,34 @@
|
||||
- name: Download and verify the netbird archive
|
||||
get_url:
|
||||
url: "https://github.com/netbirdio/netbird/releases/download/v{{ netbird_version }}/netbird_{{ netbird_version }}_linux_{{ ansible_facts['architecture'] }}.tar.gz"
|
||||
dest: "/tmp/netbird-{{ netbird_version }}.linux-amd64.tar.gz"
|
||||
checksum: "sha256:{{ netbird_sha256 }}"
|
||||
register: download_result
|
||||
|
||||
- name: Unarchive netbird binary
|
||||
unarchive:
|
||||
src: "{{ download_result.dest }}"
|
||||
dest: "/tmp/netbird_{{ netbird_version }}"
|
||||
remote_src: true # Indicates the source file is on the remote host
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0755
|
||||
|
||||
- name: Copy netbird binary to /usr/local/bin
|
||||
copy:
|
||||
src: "/tmp/netbird_{{ netbird_version }}/netbird"
|
||||
dest: "/usr/local/bin/netbird-{{ netbird_version }}"
|
||||
owner: root
|
||||
group: root
|
||||
mode: '0755'
|
||||
remote_src: yes
|
||||
|
||||
- name: Create netbird binary symlink
|
||||
file:
|
||||
src: "/usr/local/bin/netbird-{{ netbird_version }}"
|
||||
dest: "/usr/local/bin/netbird"
|
||||
state: link
|
||||
owner: root
|
||||
group: root
|
||||
mode: '0755' # Permissions for the target file
|
||||
force: yes
|
||||
Reference in New Issue
Block a user