file_from_http_server

Download a file if it does not exist, using curl with a fallback on wget.

⚙️ Compatible targets: Linux, Windows

Parameters

NameDocumentation
sourceURL to download from.

This parameter is required.
pathFile destination (absolute path on the target node).

This parameter is required.

Outcome conditions

You need to replace ${path} with its actual canonified value.

  • ✅ Ok: file_from_http_server_${path}_ok
    • ☑️ Already compliant: file_from_http_server_${path}_kept
    • 🟨 Repaired: file_from_http_server_${path}_repaired
  • ❌ Error: file_from_http_server_${path}_error

Example

method: file_from_http_server
params:
  path: VALUE
  source: VALUE

Documentation

This method finds a HTTP command-line tool and downloads the given source into the destination if it does not exist yet.

This method will NOT update the file after the first download until its removal.

On Linux based nodes it will tries curl first and fallback with wget if needed. On Windows based nodes, only curl will be used.