[build-system]
requires = [
  "setuptools >= 64.0.0", # required by pyproject+setuptools_scm integration

]
build-backend = "setuptools.build_meta"

[project]
# https://peps.python.org/pep-0621/#readme
requires-python = ">=3.10"
version = "25.8.12"
name = "molecule-plugins"
description = "Molecule Plugins"
readme = "README.md"
authors = [{ "name" = "Sorin Sbarnea", "email" = "sorin.sbarnea@gmail.com" }]
maintainers = [{ "name" = "Sorin Sbarnea", "email" = "sorin.sbarnea@gmail.com" }]
license = { text = "MIT" }
classifiers = [
  "Development Status :: 5 - Production/Stable",
  "Environment :: Console",
  "Intended Audience :: Developers",
  "Intended Audience :: Information Technology",
  "Intended Audience :: System Administrators",
  "License :: OSI Approved :: MIT License",
  "Operating System :: MacOS",
  "Operating System :: POSIX",
  "Programming Language :: Python :: 3",
  "Programming Language :: Python :: 3.10",
  "Programming Language :: Python :: 3.11",
  "Programming Language :: Python :: 3.12",
  "Programming Language :: Python :: 3 :: Only",
  "Programming Language :: Python",
  "Topic :: System :: Systems Administration",
  "Topic :: Software Development :: Quality Assurance",
  "Topic :: Software Development :: Testing",
  "Topic :: Utilities",
]
keywords = ["ansible", "testing", "molecule", "plugin"]
dependencies = [
    # molecule plugins are not allowed to mention Ansible as a direct dependency
    "molecule >= 25.1.0",
]

[project.urls]
homepage = "https://github.com/ansible-community/molecule-plugins"
documentation = "https://molecule.readthedocs.io/"
repository = "https://github.com/ansible-community/molecule-plugins"
changelog = "https://github.com/ansible-community/molecule-plugins/releases"

[project.optional-dependencies]
test = [
    "pytest-helpers-namespace >= 2019.1.8",
    "molecule[test] >= 25.1.0"
]
azure = []
docker = [
    # selinux python module is needed as least by ansible-docker modules
    # and allows use of isolated (default) virtualenvs. It does not avoid need
    # to install the system selinux libraries but it will provide a clear
    # message when user has to do that.
    'selinux; sys_platform=="linux2"',
    'selinux; sys_platform=="linux"',
    "docker >= 4.3.1",
    "requests"  # also required by docker
]
ec2 = []
gce = [
    "requests >= 2.31.0",
    "google-auth >= 2.28.2",
]
podman = [
]
selinux = [
    # selinux python module is needed as least by podman and docker on systems
    # that do have selinux enabled and where code is running inside of an
    # isolated (default) virtualenv. It does not avoid need to install the
    # system selinux libraries but it will provide a clear message when user
    # has to do that.
    'selinux; sys_platform=="linux2"',
    'selinux; sys_platform=="linux"',
]
vagrant = [
    "python-vagrant",
]
openstack = [
    "openstacksdk >= 1.1.0"
]

[tool.ruff]
lint.ignore = [
  "E501", # we use black
  # we deliberately ignore these:
  "EM102",
  # temporary disabled until we either fix them or decide to ignore them:
  "A001",
  "ANN",
  "ARG",
  "B006",
  "B028",
  "BLE",
  "C901",
  "COM812",
  "D",
  "DTZ",
  "FBT",
  "INP",
  "ISC",
  "N",
  "PERF203",
  "PGH",
  "PLR",
  "PT",
  "PTH",
  "RET",
  "S",
  # not sure we'll open a bug for every TODO.
  "TD003",
  "FIX002",
  "TRY",
]
lint.select = ["ALL"]
target-version = "py39"
# Same as Black.
line-length = 88

[tool.ruff.lint.flake8-pytest-style]
parametrize-values-type = "tuple"

[tool.ruff.lint.isort]
known-first-party = ["molecule_plugins"]

[project.entry-points."molecule.driver"]
azure = "molecule_plugins.azure.driver:Azure"
containers = "molecule_plugins.containers.driver:Container"
docker = "molecule_plugins.docker.driver:Docker"
ec2 = "molecule_plugins.ec2.driver:EC2"
gce = "molecule_plugins.gce.driver:GCE"
podman = "molecule_plugins.podman.driver:Podman"
vagrant = "molecule_plugins.vagrant.driver:Vagrant"
openstack = "molecule_plugins.openstack.driver:Openstack"
