From 8c07bea60f4b64d7b5f48d1593c57e5b028a89b8 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Fri, 30 Jul 2021 23:21:51 +0200 Subject: finalize new dolmetsch-raspi role --- roles/streaming/dolmetsch-raspi/defaults/main.yml | 4 ++-- roles/streaming/dolmetsch-raspi/tasks/main.yml | 15 ++++++++------- .../dolmetsch-raspi/templates/dolmetschctl.service.j2 | 2 +- .../dolmetsch-raspi/templates/dolmetschctld.service.j2 | 2 +- 4 files changed, 12 insertions(+), 11 deletions(-) (limited to 'roles/streaming/dolmetsch-raspi') diff --git a/roles/streaming/dolmetsch-raspi/defaults/main.yml b/roles/streaming/dolmetsch-raspi/defaults/main.yml index 4130fdf0..b4db1e02 100644 --- a/roles/streaming/dolmetsch-raspi/defaults/main.yml +++ b/roles/streaming/dolmetsch-raspi/defaults/main.yml @@ -1,6 +1,6 @@ --- -dolmetsch_raspi_golang_version: 1.11.5 -dolmetsch_raspi_golang_checksum: "sha256:b26b53c94923f78955236386fee0725ef4e76b6cb47e0df0ed0c0c4724e7b198" +dolmetsch_raspi_golang_version: 1.16.6 +dolmetsch_raspi_golang_checksum: "sha256:b1ca342e81897da3f25da4e75ae29b267db1674fe7222d9bfc4c666bcf6fce69" # dolmetsch_raspi_server_address: # dolmetsch_raspi_client_address: diff --git a/roles/streaming/dolmetsch-raspi/tasks/main.yml b/roles/streaming/dolmetsch-raspi/tasks/main.yml index 2240d211..e3f6137e 100644 --- a/roles/streaming/dolmetsch-raspi/tasks/main.yml +++ b/roles/streaming/dolmetsch-raspi/tasks/main.yml @@ -38,20 +38,21 @@ dest: /usr/local copy: no -- name: prepare dolmetschctl install path - file: - path: /opt/dolmetschctl - state: directory +- name: clone dolmetschctl repo + git: + repo: https://git.spreadspace.org/dolmetschctl + dest: /opt/dolmetschctl - name: build dolmetschctl (server and client) loop: - dolmetschctl - dolmetschctld - command: "/usr/local/go/bin/go get spreadspace.org/dolmetschctl/cmd/{{ item }}" + command: "/usr/local/go/bin/go build -o {{ item }} ./cmd/{{ item }}" args: - creates: "/opt/dolmetschctl/bin/{{ item }}" + chdir: /opt/dolmetschctl + creates: "/opt/dolmetschctl/{{ item }}" environment: - GOPATH: /opt/dolmetschctl + GOPATH: /opt/.gopath - name: install dolmetschctl systemd units loop: diff --git a/roles/streaming/dolmetsch-raspi/templates/dolmetschctl.service.j2 b/roles/streaming/dolmetsch-raspi/templates/dolmetschctl.service.j2 index 909c8570..bcf2b784 100644 --- a/roles/streaming/dolmetsch-raspi/templates/dolmetschctl.service.j2 +++ b/roles/streaming/dolmetsch-raspi/templates/dolmetschctl.service.j2 @@ -2,7 +2,7 @@ Description=dolmetschctl Client [Service] -ExecStart=/opt/dolmetschctl/bin/dolmetschctl {{ dolmetsch_raspi_server_address }}:8234 +ExecStart=/opt/dolmetschctl/dolmetschctl {{ dolmetsch_raspi_server_address }}:8234 Restart=always RestartSecs=1s StartLimitBurst=10 diff --git a/roles/streaming/dolmetsch-raspi/templates/dolmetschctld.service.j2 b/roles/streaming/dolmetsch-raspi/templates/dolmetschctld.service.j2 index c8c9ca79..fc6e632d 100644 --- a/roles/streaming/dolmetsch-raspi/templates/dolmetschctld.service.j2 +++ b/roles/streaming/dolmetsch-raspi/templates/dolmetschctld.service.j2 @@ -2,7 +2,7 @@ Description=dolmetschctl Server [Service] -ExecStart=/opt/dolmetschctl/bin/dolmetschctld +ExecStart=/opt/dolmetschctl/dolmetschctld Restart=always RestartSecs=1s StartLimitBurst=10 -- cgit v1.2.3