effectivelywild.technitium_dns.technitium_dns_download_and_update_app module – Download and update an existing app

Note

This module is part of the effectivelywild.technitium_dns collection (version 0.9.1).

It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install effectivelywild.technitium_dns.

To use it in a playbook, specify: effectivelywild.technitium_dns.technitium_dns_download_and_update_app.

New in effectivelywild.technitium_dns 0.9.0

Synopsis

  • Download an app zip file from a given URL and update an existing app on the DNS server.

  • This also supports “downgrading” to an earlier version by specifying an older version URL, however this is not idempotent.

  • The URL must start with https://.

Parameters

Parameter

Comments

api_port

integer

Port for the Technitium DNS API. Defaults to 5380

Default: 5380

api_token

string / required

API token for authenticating with the Technitium DNS API

api_url

string / required

Base URL for the Technitium DNS API

name

string / required

The name of the app to update

url

string / required

The URL of the app zip file

URL must start with https://

validate_certs

boolean

Whether to validate SSL certificates when making API requests.

Choices:

  • false

  • true ← (default)

See Also

Examples

- name: Download and update Wild IP app
  technitium_dns_download_and_update_app:
    api_url: "http://localhost"
    api_token: "myapitoken"
    name: "Wild IP"
    url: "https://download.technitium.com/dns/apps/WildIpApp.zip"
  register: result

- debug:
    var: result.updated_app

- name: Update app from DNS App Store
  technitium_dns_download_and_update_app:
    api_url: "http://localhost"
    api_token: "myapitoken"
    name: "Geo Continent"
    url: "https://download.technitium.com/dns/apps/GeoContinentApp.zip"

- name: Get latest version URL from store and update app
  block:
    - name: List available apps from DNS App Store
      technitium_dns_list_store_apps:
        api_url: "http://localhost"
        api_token: "myapitoken"
      register: store_apps_list

    - name: Update Query Logs app to latest version
      technitium_dns_download_and_update_app:
        api_url: "http://localhost"
        api_token: "myapitoken"
        name: "Query Logs (Sqlite)"
        url: "{{ (store_apps_list.store_apps | selectattr('name', 'equalto', 'Query Logs (Sqlite)') | first).url }}"

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

changed

boolean

Whether the module made changes

Returned: always

Sample: true

failed

boolean

Whether the module failed

Returned: always

Sample: false

msg

string

Human-readable message about the operation

Returned: always

Sample: "App 'Wild IP' updated successfully"

updated_app

dictionary

Information about the updated app

Returned: success

dnsApps

list / elements=dictionary

List of DNS application components

Returned: always

classPath

string

Class path of the DNS app component

Returned: always

Sample: "WildIp.App"

description

string

Description of the DNS app component

Returned: always

Sample: "Returns the IP address that was embedded in the subdomain name"

isAppRecordRequestHandler

boolean

Whether this is an APP record request handler

Returned: always

Sample: true

isAuthoritativeRequestHandler

boolean

Whether this is an authoritative request handler

Returned: always

Sample: false

isPostProcessor

boolean

Whether this is a post processor

Returned: always

Sample: false

isQueryLogger

boolean

Whether this is a query logger

Returned: always

Sample: false

isRequestBlockingHandler

boolean

Whether this is a request blocking handler

Returned: always

Sample: false

isRequestController

boolean

Whether this is a request controller

Returned: always

Sample: false

name

string

Name of the updated app

Returned: always

Sample: "Wild IP"

version

string

Version of the updated app

Returned: always

Sample: "1.0"

Authors

  • Frank Muise (@effectivelywild)