devopsarr.lidarr.lidarr_media_management module – Manages Lidarr media management.

Note

This module is part of the devopsarr.lidarr collection (version 1.0.0).

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 devopsarr.lidarr.

To use it in a playbook, specify: devopsarr.lidarr.lidarr_media_management.

New in devopsarr.lidarr 1.0.0

Synopsis

  • Manages Lidarr media management.

Parameters

Parameter

Comments

allow_fingerprinting

string

Allow fingerprinting.

Choices:

  • "always" ← (default)

  • "newFiles"

  • "never"

auto_rename_folders

boolean / required

Auto rename folders.

Choices:

  • false

  • true

auto_unmonitor_previously_downloaded_tracks

boolean / required

Auto unmonitor previously downloaded tracks.

Choices:

  • false

  • true

chmod_folder

string / required

Permission in linux format.

chown_group

string / required

Linux group.

boolean / required

Copy using hardlinks.

Choices:

  • false

  • true

create_empty_artist_folders

boolean / required

create empty artist folder.

Choices:

  • false

  • true

delete_empty_folders

boolean / required

Delete empty folders.

Choices:

  • false

  • true

download_propers_and_repacks

string / required

Download propers and repack.

Choices:

  • "preferAndUpgrade"

  • "doNotUpgrade"

  • "doNotPrefer"

enable_media_info

boolean / required

Enable media info flag.

Choices:

  • false

  • true

extra_file_extensions

string / required

Comma separated list of extra files extension to be imported.

file_date

string / required

File date modification.

Choices:

  • "none"

  • "albumReleaseDate"

import_extra_files

boolean / required

Import extra files flag.

Choices:

  • false

  • true

lidarr_api_key

string / required

API key for Lidarr authentication.

lidarr_url

string / required

Full Lidarr URL with protocol and port (e.g. `https://test.lidarr.tv:8686`)

minimum_free_space_when_importing

integer / required

Minimum free space when importing.

paths_default_static

boolean / required

Paths default static.

Choices:

  • false

  • true

recycle_bin

string / required

Bin path.

recycle_bin_cleanup_days

integer / required

Recycle bin days.

rescan_after_refresh

string / required

Rescan after refresh.

Choices:

  • "always"

  • "afterManual"

  • "never"

set_permissions_linux

boolean / required

Set linux permission flag.

Choices:

  • false

  • true

skip_free_space_check_when_importing

boolean / required

Skip free space check when importing.

Choices:

  • false

  • true

watch_library_for_changes

boolean

Watch library for changes flag.

Choices:

  • false ← (default)

  • true

Notes

Note

  • for authentication, you can set service_account_file using the c(LIDARR_URL) env variable.

  • for authentication, you can set service_account_contents using the c(LIDARR_API_KEY) env variable.

Examples

---
# update media management
- name: Update media management
  devopsarr.lidarr.lidarr_media_management:
    chmod_folder: "755"
    rescan_after_refresh: "always"
    recycle_bin: ""
    file_date: "none"
    extra_file_extensions: "info"
    download_propers_and_repacks: "doNotPrefer"
    allow_fingerprinting: "newFiles"
    chown_group: "arrs"
    minimum_free_space_when_importing: 100
    recycle_bin_cleanup_days: 7
    auto_unmonitor_previously_downloaded_tracks: true
    skip_free_space_check_when_importing: true
    set_permissions_linux: true
    import_extra_files: true
    enable_media_info: true
    delete_empty_folders: true
    create_empty_artist_folders: true
    copy_using_hardlinks: true
    paths_default_static: false
    auto_rename_folders: true

Return Values

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

Key

Description

allow_fingerprinting

string

Allow fingerprinting.

Returned: always

Sample: "always"

auto_rename_folders

boolean

Auto rename folders.

Returned: always

Sample: true

auto_unmonitor_previously_downloaded_tracks

boolean

Auto unmonitor previously downloaded tracks.

Returned: always

Sample: true

chmod_folder

string

Permission in linux format.

Returned: always

Sample: "755"

chown_group

string

Linux group.

Returned: always

Sample: "arrs"

boolean

Copy using hardlinks.

Returned: always

Sample: true

create_empty_artist_folders

boolean

create empty artist folder.

Returned: always

Sample: true

delete_empty_folders

boolean

Delete empty folders.

Returned: always

Sample: true

download_propers_and_repacks

string

Download propers and repack.

Returned: always

Sample: "preferAndUpgrade"

enable_media_info

boolean

Enable media info flag.

Returned: always

Sample: true

extra_file_extensions

string

Comma separated list of extra files extension to be imported.

Returned: always

Sample: "srt,info"

file_date

string

File date modification.

Returned: always

Sample: "localAirDate"

id

integer

Media management ID.

Returned: always

Sample: 1

import_extra_files

boolean

Import extra files flag.

Returned: always

Sample: true

minimum_free_space_when_importing

integer

Minimum free space when importing.

Returned: always

Sample: 100

paths_default_static

boolean

Paths default static.

Returned: always

Sample: true

recycle_bin

string

Bin path.

Returned: always

Sample: "/tmp"

recycle_bin_cleanup_days

integer

Recycle bin days.

Returned: always

Sample: 7

rescan_after_refresh

string

Rescan after refresh.

Returned: always

Sample: "afterManual"

set_permissions_linux

boolean

Set linux permission flag.

Returned: always

Sample: true

skip_free_space_check_when_importing

boolean

Skip free space check when importing.

Returned: always

Sample: true

watch_library_for_changes

boolean

Watch library for changes flag.

Returned: always

Sample: false

Authors

  • Fuochi (@Fuochi)