module "airflow" {
  source = "../../../../../../terraform-airflow-fork"

  environment        = var.environment
  service_name       = "${var.service_name}-airflow"
  application_family = var.application_family

  airflow_configuration_options = {
    "webserver.default_ui_timezone" = "America/New_York"
  }

  bucket_name              = local.airflow_bucket_name
  bucket_dags_path         = "airflow/dags"
  bucket_plugins_path      = "airflow/plugins.zip"
  bucket_requirements_path = "airflow/requirements.txt"

  airflow_external_policies_to_attach = [
    aws_iam_policy.bucket_access_policy.name,
  ]
}
