fast2dev 1.0.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- f2dev/__init__.py +1 -0
- f2dev/__main__.py +5 -0
- f2dev/_bundle/platform/.dockerignore +80 -0
- f2dev/_bundle/platform/.gitignore +82 -0
- f2dev/_bundle/platform/LICENSE +202 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/template_values.yaml +1731 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/Chart.yaml +9 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-airflow-deploy.yaml +60 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-bi-sync.yaml +46 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-checkout.yaml +49 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-console-sync.yaml +41 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-e2e-label.yaml +48 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-e2e-run.yaml +43 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-e2e-teardown.yaml +47 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-governance.yaml +40 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-lint.yaml +37 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-notify.yaml +32 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-quality.yaml +38 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-refresh.yaml +36 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-supersede.yaml +30 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/block-tags.yaml +44 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/pipeline-branch.yaml +138 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/pipeline-main.yaml +150 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/files/pipeline-pr.yaml +184 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/templates/NOTES.txt +18 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/templates/settings-configmap.yaml +14 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/templates/workflowtemplates.yaml +31 -0
- f2dev/_bundle/platform/charts/data_services_charts/argo_workflows/workflow_templates/values.yaml +41 -0
- f2dev/_bundle/platform/charts/data_services_charts/cicd_workload_runner/github/template_github_values.yaml +436 -0
- f2dev/_bundle/platform/charts/data_services_charts/cicd_workload_runner/github/template_github_values_extra.yaml +49 -0
- f2dev/_bundle/platform/charts/data_services_charts/cicd_workload_runner/gitlab/template_gitlab_values.yaml +551 -0
- f2dev/_bundle/platform/charts/data_services_charts/cicd_workload_runner/gitlab/template_gitlab_values_extra.yaml +9 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_analysis/lightdash/template_values.yaml +359 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_analysis/metabase/template_values.yaml +384 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_analysis/superset/template_values.yaml +1562 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_analysis/template_values.yaml +269 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/.helmignore +15 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/Chart.yaml +20 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/template_values.yaml.j2 +175 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/NOTES.txt +19 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/_helpers.tpl +50 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/cicd-rbac.yaml +30 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/configmap.yaml +142 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/extras.yaml +14 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/ingress.yaml +69 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/promtail-configmap.yaml +68 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/secret.yaml +31 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/service.yaml +15 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/serviceaccount.yaml +12 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/statefulset.yaml +276 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/valkey.yaml +113 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/templates/warehouse-stats-cronjob.yaml +107 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_control_plane/values.yaml +828 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_dbt_server/template_values.yaml +385 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_governance/template_dh_prerequisites_values.yaml +118 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_governance/template_dh_values.yaml +1671 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_governance/template_kafka_values.yaml +112 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_governance/template_opensearch_values.yaml +662 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_governance/template_values.yaml +738 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_mcp_hub/hub/Chart.yaml +6 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_mcp_hub/hub/files/argo-openapi.json +681 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_mcp_hub/hub/templates/_helpers.tpl +17 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_mcp_hub/hub/templates/argo-rbac.yaml +35 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_mcp_hub/hub/templates/backends.yaml +327 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_mcp_hub/hub/templates/gateway.yaml +150 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_mcp_hub/hub/values.yaml +91 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_mcp_hub/template_values.yaml +142 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_modeling/template_values.yaml +1167 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_modeling/template_values_extra.yaml +99 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/airflow-cleanup/Dockerfile +10 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/airflow-cleanup/build.sh +38 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/airflow-cleanup/cleanup.py +452 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/airflow-cleanup/requirements.txt +3 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/docs/keycloak-oidc-setup.md +106 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/template_values.yaml +5536 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/template_values_extra.yaml +379 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/webserver-config/configmap.yaml +459 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/webserver-config/fast2dev_auth.py +285 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/webserver-config/fast2dev_mcp_plugin.py +24 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_orchestration/webserver-config/webserver_config.py +130 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte-cleanup/Dockerfile +10 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte-cleanup/build.sh +38 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte-cleanup/cleanup.py +749 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte-cleanup/k8s/configmap.yaml +24 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte-cleanup/k8s/cronjob.yaml +137 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte-cleanup/requirements.txt +3 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/.helmignore +26 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/Chart.lock +3 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/Chart.yaml +15 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/README.md +243 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/NOTES.txt +31 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/_helpers.tpl +245 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/_images.tpl +17 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-auth-secret.yaml +35 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-bootloader/bootloader-secrets.yaml +19 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-bootloader/pod.yaml +126 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-connector-rollout-worker/deployment.yaml +171 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-cron/cron-secrets.yaml +19 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-cron/deployment.yaml +149 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-db.yaml +88 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-direct-job-runner/_helpers.tpl +111 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-direct-job-runner/deployment.yaml +169 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-direct-job-runner/hpa.yaml +23 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-direct-job-runner/pdb.yaml +17 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-direct-job-runner/service.yaml +25 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-direct-job-runner/serviceaccount.yaml +10 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-featureflag-server/deployment.yaml +161 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-featureflag-server/service.yaml +25 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-keycloak/service.yaml +62 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-keycloak/statefulset.yaml +182 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-manifest-server/_helpers.tpl +54 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-manifest-server/deployment.yaml +152 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-manifest-server/service.yaml +23 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-manifest-server/serviceaccount.yaml +10 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-metrics/deployment.yaml +124 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-server/deployment.yaml +227 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-server/service.yaml +29 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-stigg-sidecar/deployment.yaml +184 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-stigg-sidecar/service.yaml +21 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-temporal/configmap.yaml +55 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-temporal/deployment.yaml +220 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-temporal/service.yaml +21 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-temporal-ui/deployment.yaml +122 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-temporal-ui/service.yaml +23 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-webapp/deployment.yaml +146 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-webapp/ingress.yaml +63 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-webapp/service.yaml +32 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-worker/deployment.yaml +229 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-workload-api-server/deployment.yaml +191 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-workload-api-server/service.yaml +25 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-workload-launcher/deployment.yaml +232 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/airbyte-workload-launcher/jobs-secrets.yaml +21 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_auth.tpl +944 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_aws.tpl +109 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_cluster.tpl +82 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_common.tpl +370 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_connector.tpl +58 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_connectorRollout.tpl +141 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_connectorRolloutWorker.tpl +56 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_cron.tpl +62 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_customerio.tpl +56 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_database.tpl +375 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_dataplaneGroups.tpl +38 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_directJobRunner.tpl +122 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_featureFlags.tpl +126 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_java.tpl +38 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_jobs.tpl +422 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_keycloak.tpl +542 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_logging.tpl +38 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_metrics.tpl +214 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_micronaut.tpl +43 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_minio.tpl +64 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_secretsManager.tpl +628 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_server.tpl +533 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_shopify.tpl +83 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_stigg.tpl +157 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_storage.tpl +468 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_temporal.tpl +943 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_topology.tpl +98 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_tracking.tpl +82 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_webapp.tpl +38 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_worker.tpl +366 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_workloadApiServer.tpl +62 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_workloadLauncher.tpl +395 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/config/_workloads.tpl +770 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/env-configmap.yaml +62 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/gcs-log-creds-secret.yaml +19 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/ingress.yaml +69 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/minio.yaml +161 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/secret.yaml +31 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/serviceaccount.yaml +50 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/telemetry-configmap.yaml +32 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/templates/tests/test-webapp.yaml +34 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte/values.yaml +3158 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte-metrics-fast2dev-ddp/.helmignore +12 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte-metrics-fast2dev-ddp/Chart.yaml +16 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte-metrics-fast2dev-ddp/README.md +172 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte-metrics-fast2dev-ddp/templates/_helpers.tpl +42 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte-metrics-fast2dev-ddp/templates/deployment.yaml +105 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte-metrics-fast2dev-ddp/templates/externalsecret.yaml +23 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte-metrics-fast2dev-ddp/templates/pdb.yaml +15 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte-metrics-fast2dev-ddp/templates/service.yaml +18 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/airbyte_chart/airbyte-metrics-fast2dev-ddp/values.yaml +97 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/feature-flags-configmap.yaml +16 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/template_metrics_values.yaml +13 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/template_oauth2proxy_values.yaml +1200 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_replication/template_values.yaml +3255 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/Chart.yaml +7 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/conf/hazelcast-client.yaml +27 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/conf/hazelcast-master.yaml +38 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/conf/hazelcast-worker.yaml +29 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/conf/jvm_client_options +24 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/conf/jvm_master_options +6 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/conf/jvm_worker_options +6 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/conf/log4j2.properties +109 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/conf/seatunnel.yaml +36 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/templates/_helpers.tpl +70 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/templates/configmap.yaml +11 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/templates/deployment-master.yaml +120 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/templates/deployment-worker.yaml +118 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/templates/rbac.yaml +32 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/templates/services.yaml +33 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/seatunnel/values.yaml +101 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/template_oauth2proxy_values.yaml +196 -0
- f2dev/_bundle/platform/charts/data_services_charts/data_streaming/template_values.yaml +75 -0
- f2dev/_bundle/platform/charts/data_services_charts/object_storage_operator/template_values.yaml +506 -0
- f2dev/_bundle/platform/charts/infra_services_charts/cert_manager/csi_driver_values.yaml +193 -0
- f2dev/_bundle/platform/charts/infra_services_charts/cert_manager/template_pdns_webhook_values.yaml +91 -0
- f2dev/_bundle/platform/charts/infra_services_charts/cert_manager/template_values.yaml +1777 -0
- f2dev/_bundle/platform/charts/infra_services_charts/cert_manager/template_values_extra.yaml +253 -0
- f2dev/_bundle/platform/charts/infra_services_charts/cluster_cleaner/template_values.yaml +57 -0
- f2dev/_bundle/platform/charts/infra_services_charts/external_dns/template_values.yaml +476 -0
- f2dev/_bundle/platform/charts/infra_services_charts/external_dns/template_values_extra.yaml +131 -0
- f2dev/_bundle/platform/charts/infra_services_charts/idp_sso_manager/realm_template.json +4785 -0
- f2dev/_bundle/platform/charts/infra_services_charts/idp_sso_manager/template_values.yaml +657 -0
- f2dev/_bundle/platform/charts/infra_services_charts/pvc_autoscaller/template_values.yaml +36 -0
- f2dev/_bundle/platform/charts/infra_services_charts/pvc_autoscaller/template_values_extra.yaml +352 -0
- f2dev/_bundle/platform/charts/infra_services_charts/secret_manager/template_values.yaml +1218 -0
- f2dev/_bundle/platform/charts/infra_services_charts/secret_manager/template_values_extra.yaml +845 -0
- f2dev/_bundle/platform/charts/infra_services_charts/secret_manager_operator/template_values.yaml +561 -0
- f2dev/_bundle/platform/charts/infra_services_charts/secret_manager_operator/template_values_extra.yaml +23 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_logs/template_alloy_events_values.yaml +59 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_logs/template_alloy_values.yaml +185 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_logs/template_loki_values.yaml +108 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_metrics/template_values.yaml +1530 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/00-main/.gitkeep +0 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/00-main/f2d-main.json +2871 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/01-platform/.gitkeep +0 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/01-platform/f2d-k8s-cluster.json +1751 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/01-platform/f2d-microservices.json +1682 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/01-platform/f2d-pvc-storage.json +1320 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/01-platform/f2d-service.json +1193 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/02-infrastructure/.gitkeep +0 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/02-infrastructure/f2d-cert-manager.json +755 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/02-infrastructure/f2d-keycloak.json +746 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/02-infrastructure/f2d-object-storage.json +881 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/02-infrastructure/f2d-postgresql.json +1590 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/02-infrastructure/f2d-traefik.json +1375 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/.gitkeep +0 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-cicd-workflows-trends.json +1916 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-cicd-workflows.json +1330 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-analysis.json +631 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-freshness.json +1362 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-governance.json +1958 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-modeling.json +764 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-orchestration-trends.json +2352 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-orchestration.json +1506 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-quality.json +1549 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-replication-trends.json +2799 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-replication.json +2153 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-streaming-trends.json +1536 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/03-data-services/f2d-data-streaming.json +1209 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/04-data-warehouse/.gitkeep +0 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/04-data-warehouse-bigquery/.gitkeep +0 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/04-data-warehouse-bigquery/f2d-bigquery.json +990 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/05-logs/.gitkeep +0 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/05-logs/f2d-logs.json +630 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/folders.yaml +17 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/dashboards/requirements.yaml +8 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/template_alerts_cm.yaml +2031 -0
- f2dev/_bundle/platform/charts/infra_services_charts/services_monitoring/template_values.yaml +1315 -0
- f2dev/_bundle/platform/charts/infra_services_charts/stackgres_postgres_db/template_values.yaml +550 -0
- f2dev/_bundle/platform/charts/infra_services_charts/stackgres_postgres_db/template_values_extra.yaml +742 -0
- f2dev/_bundle/platform/charts/infra_services_charts/traefik_lb/template_values.yaml +1758 -0
- f2dev/_bundle/platform/cli/README.md +866 -0
- f2dev/_bundle/platform/cli/__init__.py +42 -0
- f2dev/_bundle/platform/cli/__main__.py +17 -0
- f2dev/_bundle/platform/cli/cert_providers.py +369 -0
- f2dev/_bundle/platform/cli/command_record.py +144 -0
- f2dev/_bundle/platform/cli/config/data_services_config.json +217 -0
- f2dev/_bundle/platform/cli/config/environment_profiles.yaml +183 -0
- f2dev/_bundle/platform/cli/config/images.json +129 -0
- f2dev/_bundle/platform/cli/config/infrastructure_services_config.json +141 -0
- f2dev/_bundle/platform/cli/config.py +252 -0
- f2dev/_bundle/platform/cli/deployment_configuration_aws_example.yaml +117 -0
- f2dev/_bundle/platform/cli/deployment_configuration_gcp_example.yaml +130 -0
- f2dev/_bundle/platform/cli/deployment_configuration_onprem_example.yaml +71 -0
- f2dev/_bundle/platform/cli/destroy.py +677 -0
- f2dev/_bundle/platform/cli/dns_check.py +27 -0
- f2dev/_bundle/platform/cli/dns_providers.py +405 -0
- f2dev/_bundle/platform/cli/exit_codes.py +32 -0
- f2dev/_bundle/platform/cli/fixers.py +56 -0
- f2dev/_bundle/platform/cli/generate_only.py +336 -0
- f2dev/_bundle/platform/cli/health_report.py +114 -0
- f2dev/_bundle/platform/cli/logging.py +206 -0
- f2dev/_bundle/platform/cli/main.py +5293 -0
- f2dev/_bundle/platform/cli/precheck.py +1523 -0
- f2dev/_bundle/platform/cli/prerequisites/README.md +208 -0
- f2dev/_bundle/platform/cli/prerequisites/install-prerequisites.bat +107 -0
- f2dev/_bundle/platform/cli/prerequisites/install-prerequisites.ps1 +343 -0
- f2dev/_bundle/platform/cli/prerequisites/install-prerequisites.sh +207 -0
- f2dev/_bundle/platform/cli/prerequisites/linux/install-linux.sh +775 -0
- f2dev/_bundle/platform/cli/prerequisites/macos/install-macos.sh +634 -0
- f2dev/_bundle/platform/cli/prerequisites/requirements.txt +41 -0
- f2dev/_bundle/platform/cli/prerequisites/verify-prerequisites.ps1 +150 -0
- f2dev/_bundle/platform/cli/prerequisites/verify-prerequisites.sh +418 -0
- f2dev/_bundle/platform/cli/prerequisites/versions.yaml +43 -0
- f2dev/_bundle/platform/cli/prerequisites/windows/install-windows.ps1 +1005 -0
- f2dev/_bundle/platform/cli/restore.py +179 -0
- f2dev/_bundle/platform/cli/service_gates.py +160 -0
- f2dev/_bundle/platform/cli/state.py +332 -0
- f2dev/_bundle/platform/cli/wizard.py +782 -0
- f2dev/_bundle/platform/cli.py +235 -0
- f2dev/_bundle/platform/deployers/__init__.py +4 -0
- f2dev/_bundle/platform/deployers/base_deployer.py +8 -0
- f2dev/_bundle/platform/deployers/clouds/__init__.py +0 -0
- f2dev/_bundle/platform/deployers/clouds/aws_cloud.py +619 -0
- f2dev/_bundle/platform/deployers/clouds/azure_cloud.py +0 -0
- f2dev/_bundle/platform/deployers/clouds/google_cloud.py +785 -0
- f2dev/_bundle/platform/deployers/clouds/terragrunt_progress.py +56 -0
- f2dev/_bundle/platform/deployers/services/data_services/1.0_cicd_workload_runner.py +644 -0
- f2dev/_bundle/platform/deployers/services/data_services/12.0_control_plane.py +321 -0
- f2dev/_bundle/platform/deployers/services/data_services/13.0_data_mcp_hub.py +362 -0
- f2dev/_bundle/platform/deployers/services/data_services/2.0_object_storage_operator.py +416 -0
- f2dev/_bundle/platform/deployers/services/data_services/2.5_services_logs.py +482 -0
- f2dev/_bundle/platform/deployers/services/data_services/3.0_data_cicd_workflows.py +361 -0
- f2dev/_bundle/platform/deployers/services/data_services/4.0_data_replication.py +534 -0
- f2dev/_bundle/platform/deployers/services/data_services/4.5_data_streaming.py +303 -0
- f2dev/_bundle/platform/deployers/services/data_services/5.0_data_orchestration.py +760 -0
- f2dev/_bundle/platform/deployers/services/data_services/6.0_data_modeling.py +753 -0
- f2dev/_bundle/platform/deployers/services/data_services/7.0_data_governance.py +795 -0
- f2dev/_bundle/platform/deployers/services/data_services/8.0_data_analysis.py +587 -0
- f2dev/_bundle/platform/deployers/services/infra_services/1.0_secret_operator.py +467 -0
- f2dev/_bundle/platform/deployers/services/infra_services/10.0_cluster_pvc_autoscaller.py +500 -0
- f2dev/_bundle/platform/deployers/services/infra_services/2.0_cert_manager.py +963 -0
- f2dev/_bundle/platform/deployers/services/infra_services/3.0_external_dns.py +823 -0
- f2dev/_bundle/platform/deployers/services/infra_services/4.0_traefik_lb.py +604 -0
- f2dev/_bundle/platform/deployers/services/infra_services/5.0_stackgres_postgresql.py +652 -0
- f2dev/_bundle/platform/deployers/services/infra_services/6.0_services_metrics.py +515 -0
- f2dev/_bundle/platform/deployers/services/infra_services/7.0_services_monitoring.py +787 -0
- f2dev/_bundle/platform/deployers/services/infra_services/8.0_cluster_cleaner.py +439 -0
- f2dev/_bundle/platform/deployers/services/infra_services/9.0_idp_sso_manager.py +790 -0
- f2dev/_bundle/platform/readme.md +47 -0
- f2dev/_bundle/platform/requirements.txt +14 -0
- f2dev/_bundle/platform/terraform/aws_cloud/templates/backend.tf_template +10 -0
- f2dev/_bundle/platform/terraform/aws_cloud/templates/defaults.yaml_template +11 -0
- f2dev/_bundle/platform/terraform/aws_cloud/templates/env.yaml_template +2 -0
- f2dev/_bundle/platform/terraform/aws_cloud/templates/root.hcl_advanced_template +134 -0
- f2dev/_bundle/platform/terraform/aws_cloud/templates/root.hcl_basic_template +134 -0
- f2dev/_bundle/platform/terraform/aws_cloud/templates/terragrunt.hcl_advanced_template +134 -0
- f2dev/_bundle/platform/terraform/aws_cloud/templates/terragrunt.hcl_basic_template +134 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/01-apps-vpc/terragrunt.hcl +26 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/02-create-dns-ns-record/terragrunt.hcl +16 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/03-eks-cluster/terragrunt.hcl +21 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/04-external_dns_sa/terragrunt.hcl +28 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/bi-platform/01-apps-vpc/terragrunt.hcl +25 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/bi-platform/02-eks-cluster/terragrunt.hcl +32 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/bi-platform/03-external-dns-irsa/terragrunt.hcl +34 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/bi-platform/04-cert-manager-irsa/terragrunt.hcl +34 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/bi-platform/05-create-dns-zone/terragrunt.hcl +22 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/bi-platform/06-create-dns-ns-record/terragrunt.hcl +44 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/bi-platform/empty.yaml +1 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/empty.yaml +1 -0
- f2dev/_bundle/platform/terraform/aws_cloud/terragrunt/env.hcl +2 -0
- f2dev/_bundle/platform/terraform/azure_cloud/README.md +3 -0
- f2dev/_bundle/platform/terraform/azure_cloud/templates/_keep_structure.txt +0 -0
- f2dev/_bundle/platform/terraform/google_cloud/README.md +20 -0
- f2dev/_bundle/platform/terraform/google_cloud/templates/backend.tf_template +7 -0
- f2dev/_bundle/platform/terraform/google_cloud/templates/defaults.yaml_template +12 -0
- f2dev/_bundle/platform/terraform/google_cloud/templates/env.yaml_template +2 -0
- f2dev/_bundle/platform/terraform/google_cloud/templates/root.hcl_advanced_template +114 -0
- f2dev/_bundle/platform/terraform/google_cloud/templates/root.hcl_basic_template +116 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/.gitignore +3 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/00-create-ou-folder/terragrunt.hcl +15 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/01-create-project/terragrunt.hcl +30 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/02-enable-apis/terragrunt.hcl +25 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/03-0-apps-vpc/terragrunt.hcl +134 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/04-external-ip-traefik/terragrunt.hcl +29 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/05-create-dns-zone/terragrunt.hcl +25 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/06-create-dns-ns-record/terragrunt.hcl +43 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/07-gke-cluster/terragrunt.hcl +103 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/08-dbt_deploy_sa/terragrunt.hcl +36 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/09-dbt_sa/terragrunt.hcl +40 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/10-cert_manager_sa/terragrunt.hcl +34 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/11-external_dns_sa/terragrunt.hcl +30 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/12-monitoring_sa/terragrunt.hcl +52 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/13-data_replication_sa/terragrunt.hcl +35 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/14-data_orchestration_sa/terragrunt.hcl +35 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/15-bi_data_sa/terragrunt.hcl +43 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/16-whitelist-external-ip-on-common/terragrunt.hcl +30 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/17-kubeconfig/terragrunt.hcl +23 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/bi-platform/18-data_streaming_sa/terragrunt.hcl +24 -0
- f2dev/_bundle/platform/terraform/google_cloud/terragrunt/empty.yaml +1 -0
- f2dev/_bundle/platform/utils/__init__.py +0 -0
- f2dev/_bundle/platform/utils/customer_data_platform_repository_operator.py +1098 -0
- f2dev/_bundle/platform/utils/customer_secret_manager_operations.py +1635 -0
- f2dev/_bundle/platform/utils/environment_profiles.py +58 -0
- f2dev/_bundle/platform/utils/helm_utils.py +215 -0
- f2dev/_bundle/platform/utils/infrastructure_deployment_operator.py +1532 -0
- f2dev/_bundle/platform/utils/keycloak_realm_reconcile.py +320 -0
- f2dev/_bundle/platform/utils/kubeconfig_fixer.py +265 -0
- f2dev/_bundle/platform/utils/raw_extras.py +34 -0
- f2dev/_bundle/platform/utils/readiness.py +330 -0
- f2dev/_bundle/platform/utils/secret_structure_upgrade.py +194 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/.gitignore +7 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/README.md +33 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/analyses/.gitkeep +0 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/dbt_project.yml +52 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/macros/.gitkeep +0 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/macros/fast2dev_bq_time_zones.sql +12 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/macros/fast2dev_monitoring_grain.sql +23 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_daily_spend.sql +19 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_daily_spend.yml +25 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_model_costs_daily.sql +16 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_model_costs_daily.yml +24 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_storage_by_dataset.sql +12 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_storage_by_dataset.yml +21 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_user_costs_daily.sql +14 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_user_costs_daily.yml +22 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_weekly_kpi.sql +52 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_weekly_kpi.yml +42 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_weekly_spend.sql +74 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/marts/fast2dev_bq_weekly_spend.yml +49 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/sources/billing_export.yml +9 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/staging/fast2dev_bq_billing_export.sql +9 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/models/staging/fast2dev_bq_billing_export.yml +4 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/packages.yml +5 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/profiles.yml +15 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/scripts/run_monitoring.py +201 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/seeds/.gitkeep +0 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/snapshots/.gitkeep +0 -0
- f2dev/_bundle/platform/utils/templates/control_plane_warehouse_stats_template/bigquery_usage/tests/.gitkeep +0 -0
- f2dev/_bundle/platform/utils/templates/dry_run/gcp_sa.json +12 -0
- f2dev/_bundle/platform/utils/templates/dry_run/kubeconfig.yaml +18 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/data_orchestrator/repository_structure/README.MD +50 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/data_orchestrator/repository_structure/dags/dbt/README.MD +47 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/data_orchestrator/repository_structure/dags/fast2dev_healthcheck.py_template_airflow_3.x +158 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/bitbucket/bitbucket-pipelines.yml_template +144 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/gitea/.gitea/PR_VALIDATION.md +52 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/gitea/.gitea/pull_request_template.md +48 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/gitea/.gitea/workflows/argo-workflows.yml_template +143 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/gitea/.gitea/workflows/pr-agent.yml +30 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/gitea/.gitea/workflows/validate-pr-description.yml +38 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/github/.github/PR_VALIDATION.md +52 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/github/.github/pull_request_template.md +48 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/github/.github/workflows/argo-workflows.yml_template +143 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/github/.github/workflows/pr-agent.yml +37 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/github/.github/workflows/validate-pr-description.yml +157 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/gitlab/.gitlab/PR_VALIDATION.md +43 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/gitlab/.gitlab/merge_request_templates/Default.md +48 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/gitlab/.gitlab-ci.yml_template +181 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/repository_structure/.gitignore +21 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/repository_structure/.pr_agent.toml +82 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/repository_structure/AGENTS.md +126 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/dbt_data_model/repository_structure/README.MD +101 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/infrastructure_deployment_files/DR.md +341 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/infrastructure_deployment_files/README.md.j2 +81 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/infrastructure_deployment_files/decrypt_files.py +331 -0
- f2dev/_bundle/platform/utils/templates/git_repo_templates/infrastructure_deployment_files/encrypt_files.py +321 -0
- f2dev/_bundle/platform/utils/templates/secret_structure_template/customer_vault_structure.json +502 -0
- f2dev/_bundle/platform/utils/vault_structure_sync.py +96 -0
- f2dev/_bundle/terraform-modules/README.md +12 -0
- f2dev/_bundle/terraform-modules/aws_cloud/README.md +7 -0
- f2dev/_bundle/terraform-modules/aws_cloud/eks/addons-roles.tf +298 -0
- f2dev/_bundle/terraform-modules/aws_cloud/eks/main.tf +313 -0
- f2dev/_bundle/terraform-modules/aws_cloud/eks/outputs.tf +3 -0
- f2dev/_bundle/terraform-modules/aws_cloud/eks/policies/lb-controller-policy.json +219 -0
- f2dev/_bundle/terraform-modules/aws_cloud/eks/provider.tf +36 -0
- f2dev/_bundle/terraform-modules/aws_cloud/eks/variables.tf +107 -0
- f2dev/_bundle/terraform-modules/aws_cloud/eks/versions.tf +10 -0
- f2dev/_bundle/terraform-modules/aws_cloud/gcp_aws_zone/main.tf +25 -0
- f2dev/_bundle/terraform-modules/aws_cloud/gcp_aws_zone/provider.tf +17 -0
- f2dev/_bundle/terraform-modules/aws_cloud/gcp_aws_zone/variables.tf +41 -0
- f2dev/_bundle/terraform-modules/aws_cloud/vpc/main.tf +34 -0
- f2dev/_bundle/terraform-modules/aws_cloud/vpc/outputs.tf +44 -0
- f2dev/_bundle/terraform-modules/aws_cloud/vpc/provider.tf +12 -0
- f2dev/_bundle/terraform-modules/aws_cloud/vpc/variables.tf +118 -0
- f2dev/_bundle/terraform-modules/aws_cloud/vpc/versions.tf +10 -0
- f2dev/_bundle/terraform-modules/azure_cloud/README.md +3 -0
- f2dev/_bundle/terraform-modules/google_cloud/README.md +17 -0
- f2dev/_bundle/terraform-modules/google_cloud/artifact-registry/main.tf +8 -0
- f2dev/_bundle/terraform-modules/google_cloud/artifact-registry/providers.tf +6 -0
- f2dev/_bundle/terraform-modules/google_cloud/artifact-registry/variables.tf +17 -0
- f2dev/_bundle/terraform-modules/google_cloud/artifact-registry/versions.tf +8 -0
- f2dev/_bundle/terraform-modules/google_cloud/cloud-dns/main.tf +24 -0
- f2dev/_bundle/terraform-modules/google_cloud/cloud-dns/outputs.tf +25 -0
- f2dev/_bundle/terraform-modules/google_cloud/cloud-dns/providers.tf +7 -0
- f2dev/_bundle/terraform-modules/google_cloud/cloud-dns/variables.tf +17 -0
- f2dev/_bundle/terraform-modules/google_cloud/cloud-dns/versions.tf +9 -0
- f2dev/_bundle/terraform-modules/google_cloud/cloud-dns-recordset/main.tf +38 -0
- f2dev/_bundle/terraform-modules/google_cloud/cloud-dns-recordset/variables.tf +73 -0
- f2dev/_bundle/terraform-modules/google_cloud/cloud-dns-recordset/versions.tf +39 -0
- f2dev/_bundle/terraform-modules/google_cloud/composer/main.tf +213 -0
- f2dev/_bundle/terraform-modules/google_cloud/composer/outputs.tf +31 -0
- f2dev/_bundle/terraform-modules/google_cloud/composer/provider.tf +4 -0
- f2dev/_bundle/terraform-modules/google_cloud/composer/variables.tf +192 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-ou-folder/main.tf +29 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-ou-folder/output.tf +4 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-ou-folder/providers.tf +6 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-ou-folder/variables.tf +40 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-ou-folder/versions.tf +8 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-project/main.tf +18 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-project/output.tf +8 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-project/providers.tf +6 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-project/variables.tf +27 -0
- f2dev/_bundle/terraform-modules/google_cloud/create-project/versions.tf +9 -0
- f2dev/_bundle/terraform-modules/google_cloud/deploy_sa/README.md +188 -0
- f2dev/_bundle/terraform-modules/google_cloud/deploy_sa/main.tf +135 -0
- f2dev/_bundle/terraform-modules/google_cloud/deploy_sa/output.tf +16 -0
- f2dev/_bundle/terraform-modules/google_cloud/deploy_sa/providers.tf +6 -0
- f2dev/_bundle/terraform-modules/google_cloud/deploy_sa/variables.tf +54 -0
- f2dev/_bundle/terraform-modules/google_cloud/deploy_sa/versions.tf +17 -0
- f2dev/_bundle/terraform-modules/google_cloud/enable_apis/main.tf +14 -0
- f2dev/_bundle/terraform-modules/google_cloud/enable_apis/provider.tf +7 -0
- f2dev/_bundle/terraform-modules/google_cloud/enable_apis/variables.tf +13 -0
- f2dev/_bundle/terraform-modules/google_cloud/enable_apis/versions.tf +10 -0
- f2dev/_bundle/terraform-modules/google_cloud/external-ip/README.md +89 -0
- f2dev/_bundle/terraform-modules/google_cloud/external-ip/main.tf +17 -0
- f2dev/_bundle/terraform-modules/google_cloud/external-ip/outputs.tf +19 -0
- f2dev/_bundle/terraform-modules/google_cloud/external-ip/variables.tf +43 -0
- f2dev/_bundle/terraform-modules/google_cloud/fw-add/main.tf +24 -0
- f2dev/_bundle/terraform-modules/google_cloud/fw-add/providers.tf +6 -0
- f2dev/_bundle/terraform-modules/google_cloud/fw-add/variables.tf +37 -0
- f2dev/_bundle/terraform-modules/google_cloud/fw-add/versions.tf +9 -0
- f2dev/_bundle/terraform-modules/google_cloud/gke-cluster/README.md +10 -0
- f2dev/_bundle/terraform-modules/google_cloud/gke-cluster/main.tf +459 -0
- f2dev/_bundle/terraform-modules/google_cloud/gke-cluster/outputs.tf +44 -0
- f2dev/_bundle/terraform-modules/google_cloud/gke-cluster/provider.tf +19 -0
- f2dev/_bundle/terraform-modules/google_cloud/gke-cluster/variables.tf +354 -0
- f2dev/_bundle/terraform-modules/google_cloud/gke-cluster/versions.tf +22 -0
- f2dev/_bundle/terraform-modules/google_cloud/kubeconfig/README.md +40 -0
- f2dev/_bundle/terraform-modules/google_cloud/kubeconfig/main.tf +54 -0
- f2dev/_bundle/terraform-modules/google_cloud/kubeconfig/outputs.tf +10 -0
- f2dev/_bundle/terraform-modules/google_cloud/kubeconfig/variables.tf +24 -0
- f2dev/_bundle/terraform-modules/google_cloud/kubeconfig/versions.tf +10 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/README.md +47 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/main.tf +51 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/net-address/README.md +103 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/net-address/main.tf +71 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/net-address/outputs.tf +71 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/net-address/variables.tf +82 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/net-address/versions.tf +27 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/outputs.tf +35 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/provider.tf +4 -0
- f2dev/_bundle/terraform-modules/google_cloud/shared-vpc/variables.tf +237 -0
- f2dev/_bundle/terraform-modules/oracle_cloud/README.md +3 -0
- f2dev/launcher.py +153 -0
- fast2dev-1.0.0.dist-info/METADATA +201 -0
- fast2dev-1.0.0.dist-info/RECORD +543 -0
- fast2dev-1.0.0.dist-info/WHEEL +4 -0
- fast2dev-1.0.0.dist-info/entry_points.txt +2 -0
- fast2dev-1.0.0.dist-info/licenses/LICENSE +202 -0
- fast2dev-1.0.0.dist-info/licenses/NOTICE +6 -0
|
@@ -0,0 +1,336 @@
|
|
|
1
|
+
"""Generate-only mode: render every deployment file without touching anything remote.
|
|
2
|
+
|
|
3
|
+
The wizard and the deployers run as usual with ``dry_run=True``. This module adds the
|
|
4
|
+
safety net around them: a placeholder kubeconfig that points at no real cluster, and a
|
|
5
|
+
guard that skips any command or HTTP call that would reach a cloud, a cluster or a git
|
|
6
|
+
remote, even when a deployer forgets its own dry-run check.
|
|
7
|
+
"""
|
|
8
|
+
|
|
9
|
+
from __future__ import annotations
|
|
10
|
+
|
|
11
|
+
import os
|
|
12
|
+
import shlex
|
|
13
|
+
import subprocess
|
|
14
|
+
import time
|
|
15
|
+
import urllib.parse
|
|
16
|
+
import urllib.request
|
|
17
|
+
from contextlib import contextmanager
|
|
18
|
+
from pathlib import Path
|
|
19
|
+
|
|
20
|
+
from utils.helm_utils import GENERATE_ONLY_ENV
|
|
21
|
+
|
|
22
|
+
PLATFORM_DIR = Path(__file__).resolve().parents[1]
|
|
23
|
+
TEMPLATES_DIR = PLATFORM_DIR / "utils" / "templates" / "dry_run"
|
|
24
|
+
PLACEHOLDER_KUBECONFIG = TEMPLATES_DIR / "kubeconfig.yaml"
|
|
25
|
+
PLACEHOLDER_SA_JSON = TEMPLATES_DIR / "gcp_sa.json"
|
|
26
|
+
DEFAULT_STATE_FILE = "cli/state/generated_state.json"
|
|
27
|
+
DEPLOY_STATE_FILE = "cli/state/deployment_state.json"
|
|
28
|
+
|
|
29
|
+
REMOTE_TOOLS = {
|
|
30
|
+
"kubectl", "helm", "terragrunt", "terraform", "gcloud", "gsutil", "bq",
|
|
31
|
+
"aws", "az", "vault", "curl", "wget", "ssh", "scp", "argo", "docker", "podman",
|
|
32
|
+
}
|
|
33
|
+
REMOTE_GIT_COMMANDS = {"clone", "push", "pull", "fetch", "ls-remote", "remote", "submodule"}
|
|
34
|
+
SKIPPED_DIRS = {".venv", "__pycache__", ".git", "node_modules", ".pytest_cache", ".terragrunt-cache", ".terraform"}
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
class RemoteCallBlocked(RuntimeError):
|
|
38
|
+
"""Raised in strict mode when generate-only code tries to reach a remote system."""
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def _argv(command) -> list[str]:
|
|
42
|
+
if isinstance(command, (list, tuple)):
|
|
43
|
+
return [str(part) for part in command]
|
|
44
|
+
try:
|
|
45
|
+
return shlex.split(str(command))
|
|
46
|
+
except ValueError:
|
|
47
|
+
return str(command).split()
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
VALUE_OPTIONS = {"--kubeconfig", "--context", "-n", "--namespace", "-C", "-c", "-f", "--git-dir", "--work-tree", "-o"}
|
|
51
|
+
WRAPPERS = {"env", "sudo", "bash", "sh", "zsh", "exec"}
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
def _words(argv: list[str]) -> list[str]:
|
|
55
|
+
words, skip = [], False
|
|
56
|
+
for word in argv:
|
|
57
|
+
if skip:
|
|
58
|
+
skip = False
|
|
59
|
+
continue
|
|
60
|
+
if word in VALUE_OPTIONS:
|
|
61
|
+
skip = True
|
|
62
|
+
continue
|
|
63
|
+
if word.startswith("-") or ("=" in word and not word.startswith(("/", "."))):
|
|
64
|
+
continue
|
|
65
|
+
words.append(word)
|
|
66
|
+
return words
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
def _program(argv: list[str]) -> tuple[str, list[str]]:
|
|
70
|
+
words = _words(argv)
|
|
71
|
+
while words and os.path.basename(words[0]) in WRAPPERS:
|
|
72
|
+
words = words[1:]
|
|
73
|
+
if not words:
|
|
74
|
+
return "", []
|
|
75
|
+
return os.path.basename(words[0]), words[1:]
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
def _chunks(command) -> list[list[str]]:
|
|
79
|
+
argv = _argv(command)
|
|
80
|
+
if len(argv) >= 3 and os.path.basename(argv[0]) in WRAPPERS and "-c" in argv:
|
|
81
|
+
argv = _argv(argv[argv.index("-c") + 1])
|
|
82
|
+
text = " ".join(shlex.quote(a) if " " in a else a for a in argv)
|
|
83
|
+
for sep in ("&&", "||", "|"):
|
|
84
|
+
text = text.replace(sep, ";")
|
|
85
|
+
return [_argv(chunk) for chunk in text.split(";") if chunk.strip()]
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
def _remote_chunk(command) -> tuple[str, list[str]] | None:
|
|
89
|
+
for chunk in _chunks(command):
|
|
90
|
+
name, rest = _program(chunk)
|
|
91
|
+
if name in REMOTE_TOOLS:
|
|
92
|
+
return name, rest
|
|
93
|
+
if name == "git" and REMOTE_GIT_COMMANDS.intersection(rest[:1] or rest):
|
|
94
|
+
return name, [w for w in rest if w in REMOTE_GIT_COMMANDS][:1]
|
|
95
|
+
return None
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
def is_remote(command) -> bool:
|
|
99
|
+
"""True when ``command`` would talk to a cloud, a cluster or a git remote."""
|
|
100
|
+
return _remote_chunk(command) is not None
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
def describe(command) -> str:
|
|
104
|
+
"""Tool and subcommand only; arguments may carry secrets."""
|
|
105
|
+
found = _remote_chunk(command)
|
|
106
|
+
if found is None:
|
|
107
|
+
found = _program(_argv(command))
|
|
108
|
+
name, rest = found
|
|
109
|
+
return f"{name} {rest[0]}".strip() if rest else name
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
class _SkippedProcess:
|
|
113
|
+
returncode = 0
|
|
114
|
+
pid = 0
|
|
115
|
+
stdin = None
|
|
116
|
+
|
|
117
|
+
def __init__(self, text: bool):
|
|
118
|
+
self._empty = "" if text else b""
|
|
119
|
+
self.stdout = None
|
|
120
|
+
self.stderr = None
|
|
121
|
+
|
|
122
|
+
def poll(self):
|
|
123
|
+
return 0
|
|
124
|
+
|
|
125
|
+
def wait(self, timeout=None):
|
|
126
|
+
return 0
|
|
127
|
+
|
|
128
|
+
def communicate(self, input=None, timeout=None):
|
|
129
|
+
return self._empty, self._empty
|
|
130
|
+
|
|
131
|
+
def terminate(self):
|
|
132
|
+
pass
|
|
133
|
+
|
|
134
|
+
def kill(self):
|
|
135
|
+
pass
|
|
136
|
+
|
|
137
|
+
def __enter__(self):
|
|
138
|
+
return self
|
|
139
|
+
|
|
140
|
+
def __exit__(self, *exc):
|
|
141
|
+
return False
|
|
142
|
+
|
|
143
|
+
|
|
144
|
+
class OfflineGuard:
|
|
145
|
+
"""Skip (or, when strict, refuse) every remote call while active."""
|
|
146
|
+
|
|
147
|
+
def __init__(self, strict: bool = False, echo=print):
|
|
148
|
+
self.strict = strict
|
|
149
|
+
self.echo = echo
|
|
150
|
+
self.skipped: list[str] = []
|
|
151
|
+
self.started = time.time()
|
|
152
|
+
self._saved: list[tuple[object, str, object]] = []
|
|
153
|
+
|
|
154
|
+
def _record(self, what: str):
|
|
155
|
+
if self.strict:
|
|
156
|
+
raise RemoteCallBlocked(f"generate-only blocked: {what}")
|
|
157
|
+
self.skipped.append(what)
|
|
158
|
+
if self.echo:
|
|
159
|
+
self.echo(f"[GENERATE-ONLY] skipped: {what}")
|
|
160
|
+
|
|
161
|
+
def _patch(self, owner, name, replacement):
|
|
162
|
+
self._saved.append((owner, name, getattr(owner, name)))
|
|
163
|
+
setattr(owner, name, replacement)
|
|
164
|
+
|
|
165
|
+
def __enter__(self):
|
|
166
|
+
self.started = time.time()
|
|
167
|
+
real_run = subprocess.run
|
|
168
|
+
real_popen = subprocess.Popen
|
|
169
|
+
real_check_output = subprocess.check_output
|
|
170
|
+
real_check_call = subprocess.check_call
|
|
171
|
+
real_call = subprocess.call
|
|
172
|
+
real_system = os.system
|
|
173
|
+
real_urlopen = urllib.request.urlopen
|
|
174
|
+
|
|
175
|
+
def text_mode(kwargs):
|
|
176
|
+
return bool(kwargs.get("text") or kwargs.get("universal_newlines") or kwargs.get("encoding"))
|
|
177
|
+
|
|
178
|
+
def run(command, *args, **kwargs):
|
|
179
|
+
if is_remote(command):
|
|
180
|
+
self._record(describe(command))
|
|
181
|
+
empty = "" if text_mode(kwargs) else b""
|
|
182
|
+
return subprocess.CompletedProcess(command, 0, stdout=empty, stderr=empty)
|
|
183
|
+
return real_run(command, *args, **kwargs)
|
|
184
|
+
|
|
185
|
+
def popen(command, *args, **kwargs):
|
|
186
|
+
if is_remote(command):
|
|
187
|
+
self._record(describe(command))
|
|
188
|
+
return _SkippedProcess(text_mode(kwargs))
|
|
189
|
+
return real_popen(command, *args, **kwargs)
|
|
190
|
+
|
|
191
|
+
def check_output(command, *args, **kwargs):
|
|
192
|
+
if is_remote(command):
|
|
193
|
+
self._record(describe(command))
|
|
194
|
+
return "" if text_mode(kwargs) else b""
|
|
195
|
+
return real_check_output(command, *args, **kwargs)
|
|
196
|
+
|
|
197
|
+
def check_call(command, *args, **kwargs):
|
|
198
|
+
if is_remote(command):
|
|
199
|
+
self._record(describe(command))
|
|
200
|
+
return 0
|
|
201
|
+
return real_check_call(command, *args, **kwargs)
|
|
202
|
+
|
|
203
|
+
def call(command, *args, **kwargs):
|
|
204
|
+
if is_remote(command):
|
|
205
|
+
self._record(describe(command))
|
|
206
|
+
return 0
|
|
207
|
+
return real_call(command, *args, **kwargs)
|
|
208
|
+
|
|
209
|
+
def system(command):
|
|
210
|
+
if is_remote(command):
|
|
211
|
+
self._record(describe(command))
|
|
212
|
+
return 0
|
|
213
|
+
return real_system(command)
|
|
214
|
+
|
|
215
|
+
def urlopen(url, *args, **kwargs):
|
|
216
|
+
target = getattr(url, "full_url", url)
|
|
217
|
+
host = urllib.parse.urlsplit(str(target)).netloc or str(target)
|
|
218
|
+
self._record(f"http {host}")
|
|
219
|
+
raise OSError("generate-only: network calls are skipped")
|
|
220
|
+
|
|
221
|
+
self._patch(subprocess, "run", run)
|
|
222
|
+
self._patch(subprocess, "Popen", popen)
|
|
223
|
+
self._patch(subprocess, "check_output", check_output)
|
|
224
|
+
self._patch(subprocess, "check_call", check_call)
|
|
225
|
+
self._patch(subprocess, "call", call)
|
|
226
|
+
self._patch(os, "system", system)
|
|
227
|
+
self._patch(urllib.request, "urlopen", urlopen)
|
|
228
|
+
try:
|
|
229
|
+
import requests
|
|
230
|
+
|
|
231
|
+
def request(session, method, url, *args, **kwargs):
|
|
232
|
+
host = urllib.parse.urlsplit(str(url)).netloc or str(url)
|
|
233
|
+
self._record(f"http {host}")
|
|
234
|
+
raise requests.exceptions.ConnectionError("generate-only: network calls are skipped")
|
|
235
|
+
|
|
236
|
+
self._patch(requests.sessions.Session, "request", request)
|
|
237
|
+
except ImportError:
|
|
238
|
+
pass
|
|
239
|
+
return self
|
|
240
|
+
|
|
241
|
+
def __exit__(self, *exc):
|
|
242
|
+
while self._saved:
|
|
243
|
+
owner, name, original = self._saved.pop()
|
|
244
|
+
setattr(owner, name, original)
|
|
245
|
+
return False
|
|
246
|
+
|
|
247
|
+
|
|
248
|
+
@contextmanager
|
|
249
|
+
def generate_only_environment(strict: bool = False, echo=print):
|
|
250
|
+
"""Point every tool at the placeholder kubeconfig and guard remote calls."""
|
|
251
|
+
overrides = {"KUBECONFIG": str(PLACEHOLDER_KUBECONFIG), GENERATE_ONLY_ENV: "1"}
|
|
252
|
+
previous = {name: os.environ.get(name) for name in overrides}
|
|
253
|
+
os.environ.update(overrides)
|
|
254
|
+
try:
|
|
255
|
+
with OfflineGuard(strict=strict, echo=echo) as guard:
|
|
256
|
+
yield guard
|
|
257
|
+
finally:
|
|
258
|
+
for name, value in previous.items():
|
|
259
|
+
if value is None:
|
|
260
|
+
os.environ.pop(name, None)
|
|
261
|
+
else:
|
|
262
|
+
os.environ[name] = value
|
|
263
|
+
|
|
264
|
+
|
|
265
|
+
def files_written_since(started: float, root: Path = PLATFORM_DIR) -> list[Path]:
|
|
266
|
+
"""Files under ``root`` created or changed since ``started``, relative to ``root``."""
|
|
267
|
+
found: list[Path] = []
|
|
268
|
+
for current, dirs, files in os.walk(root):
|
|
269
|
+
dirs[:] = [d for d in dirs if d not in SKIPPED_DIRS]
|
|
270
|
+
for name in files:
|
|
271
|
+
if name.endswith((".pyc", ".log")):
|
|
272
|
+
continue
|
|
273
|
+
path = Path(current) / name
|
|
274
|
+
try:
|
|
275
|
+
if path.stat().st_mtime >= started:
|
|
276
|
+
found.append(path.relative_to(root))
|
|
277
|
+
except OSError:
|
|
278
|
+
continue
|
|
279
|
+
return sorted(found)
|
|
280
|
+
|
|
281
|
+
|
|
282
|
+
GENERATED_REPOS = Path("cli") / "state" / "generated"
|
|
283
|
+
|
|
284
|
+
|
|
285
|
+
def generated_repositories(root: Path = PLATFORM_DIR) -> dict[Path, int]:
|
|
286
|
+
"""Repository folders rendered by phase 3, with their file counts."""
|
|
287
|
+
base = root / GENERATED_REPOS
|
|
288
|
+
if not base.is_dir():
|
|
289
|
+
return {}
|
|
290
|
+
repos: dict[Path, int] = {}
|
|
291
|
+
for customer_dir in sorted(p for p in base.iterdir() if p.is_dir()):
|
|
292
|
+
for repo in sorted(p for p in customer_dir.iterdir() if p.is_dir()):
|
|
293
|
+
repos[repo.relative_to(root)] = sum(1 for f in repo.rglob("*") if f.is_file())
|
|
294
|
+
return repos
|
|
295
|
+
|
|
296
|
+
|
|
297
|
+
def group_files(paths: list[Path]) -> dict[str, list[Path]]:
|
|
298
|
+
"""Group generated files for the closing summary; repository scaffolding is listed separately."""
|
|
299
|
+
groups: dict[str, list[Path]] = {}
|
|
300
|
+
for path in paths:
|
|
301
|
+
if path.parts[:3] == GENERATED_REPOS.parts:
|
|
302
|
+
continue
|
|
303
|
+
parts = path.parts
|
|
304
|
+
if parts[:2] == ("cli", "state") and "secrets" in parts:
|
|
305
|
+
key = "Secrets"
|
|
306
|
+
elif parts[:1] == ("cli",):
|
|
307
|
+
key = "Installer state"
|
|
308
|
+
elif parts[:1] == ("terraform",):
|
|
309
|
+
key = "Infrastructure (Terraform/Terragrunt inputs)"
|
|
310
|
+
elif parts[:1] == ("charts",):
|
|
311
|
+
key = "Kubernetes (Helm values and manifests)"
|
|
312
|
+
else:
|
|
313
|
+
key = "Other"
|
|
314
|
+
groups.setdefault(key, []).append(path)
|
|
315
|
+
return groups
|
|
316
|
+
|
|
317
|
+
|
|
318
|
+
def placeholder_sa_json() -> str:
|
|
319
|
+
return PLACEHOLDER_SA_JSON.read_text()
|
|
320
|
+
|
|
321
|
+
|
|
322
|
+
__all__ = [
|
|
323
|
+
"DEFAULT_STATE_FILE",
|
|
324
|
+
"DEPLOY_STATE_FILE",
|
|
325
|
+
"PLACEHOLDER_KUBECONFIG",
|
|
326
|
+
"PLACEHOLDER_SA_JSON",
|
|
327
|
+
"OfflineGuard",
|
|
328
|
+
"RemoteCallBlocked",
|
|
329
|
+
"describe",
|
|
330
|
+
"files_written_since",
|
|
331
|
+
"generated_repositories",
|
|
332
|
+
"generate_only_environment",
|
|
333
|
+
"group_files",
|
|
334
|
+
"is_remote",
|
|
335
|
+
"placeholder_sa_json",
|
|
336
|
+
]
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
"""Platform health report: shown at the end of the wizard and by ``cli.py --check``.
|
|
2
|
+
|
|
3
|
+
✅ ready ⏳ still settling (certificates, DNS) — not a failure, re-check later ❌ broken
|
|
4
|
+
Reads the cluster only; changes nothing.
|
|
5
|
+
"""
|
|
6
|
+
from __future__ import annotations
|
|
7
|
+
|
|
8
|
+
import re
|
|
9
|
+
import socket
|
|
10
|
+
import ssl
|
|
11
|
+
import time
|
|
12
|
+
import urllib.error
|
|
13
|
+
import urllib.request
|
|
14
|
+
from typing import Callable
|
|
15
|
+
|
|
16
|
+
from utils import readiness as r
|
|
17
|
+
|
|
18
|
+
OK, WAIT, BAD = "✅", "⏳", "❌"
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def _namespaces(kc: str, wanted: list[str]) -> list[str]:
|
|
22
|
+
present = {n["metadata"]["name"] for n in r.items(["get", "ns"], kc)}
|
|
23
|
+
return [ns for ns in wanted if ns in present]
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
def _namespace_rows(kc: str, namespaces: list[str]) -> list[tuple[str, str, str]]:
|
|
27
|
+
rows, now = [], time.time()
|
|
28
|
+
for ns in namespaces:
|
|
29
|
+
failures = r._pod_failures(ns, kc, now)
|
|
30
|
+
es_waiting, es_failing = r._external_secret_status(ns, kc, now)
|
|
31
|
+
pending = r._workload_status(ns, kc) + es_waiting
|
|
32
|
+
if failures or es_failing:
|
|
33
|
+
detail = (failures + es_failing)[0].splitlines()[0]
|
|
34
|
+
rows.append((BAD, ns, detail))
|
|
35
|
+
elif pending:
|
|
36
|
+
rows.append((WAIT, ns, "not ready: " + ", ".join(pending[:3])))
|
|
37
|
+
else:
|
|
38
|
+
rows.append((OK, ns, "all workloads ready"))
|
|
39
|
+
return rows
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def _certificate_rows(kc: str) -> list[tuple[str, str, str]]:
|
|
43
|
+
rows = []
|
|
44
|
+
for cert in r.items(["get", "certificates.cert-manager.io", "-A"], kc):
|
|
45
|
+
name = f"{cert['metadata']['namespace']}/{cert['metadata']['name']}"
|
|
46
|
+
cond = r.condition(cert, "Ready") or {}
|
|
47
|
+
if cond.get("status") == "True":
|
|
48
|
+
rows.append((OK, name, "certificate issued"))
|
|
49
|
+
else:
|
|
50
|
+
rows.append((WAIT, name, (cond.get("message") or "being issued")[:120]))
|
|
51
|
+
return rows
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
def _hosts(kc: str) -> list[str]:
|
|
55
|
+
hosts = set()
|
|
56
|
+
for ing in r.items(["get", "ingress", "-A"], kc):
|
|
57
|
+
for rule in (ing.get("spec") or {}).get("rules") or []:
|
|
58
|
+
if rule.get("host"):
|
|
59
|
+
hosts.add(rule["host"])
|
|
60
|
+
for route in r.items(["get", "ingressroutes.traefik.io", "-A"], kc):
|
|
61
|
+
for rt in (route.get("spec") or {}).get("routes") or []:
|
|
62
|
+
hosts.update(re.findall(r"Host\(`([^`]+)`\)", rt.get("match", "")))
|
|
63
|
+
return sorted(hosts)
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
def _https_row(host: str) -> tuple[str, str, str]:
|
|
67
|
+
try:
|
|
68
|
+
socket.gethostbyname(host)
|
|
69
|
+
except OSError:
|
|
70
|
+
return WAIT, host, "DNS not resolving yet"
|
|
71
|
+
url = f"https://{host}/"
|
|
72
|
+
try:
|
|
73
|
+
with urllib.request.urlopen(urllib.request.Request(url, method="GET"), timeout=15) as resp:
|
|
74
|
+
code = resp.status
|
|
75
|
+
except urllib.error.HTTPError as e:
|
|
76
|
+
code = e.code
|
|
77
|
+
except urllib.error.URLError as e:
|
|
78
|
+
if isinstance(e.reason, ssl.SSLError):
|
|
79
|
+
return WAIT, host, "TLS certificate not trusted yet"
|
|
80
|
+
return BAD, host, f"unreachable: {e.reason}"
|
|
81
|
+
except (TimeoutError, OSError) as e:
|
|
82
|
+
return BAD, host, f"unreachable: {e}"
|
|
83
|
+
if code >= 500:
|
|
84
|
+
return BAD, host, f"HTTP {code}"
|
|
85
|
+
return OK, host, f"HTTPS {code}"
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
def build_report(kc: str, namespaces: list[str]) -> dict[str, list[tuple[str, str, str]]]:
|
|
89
|
+
return {
|
|
90
|
+
"Services": _namespace_rows(kc, _namespaces(kc, namespaces)),
|
|
91
|
+
"Certificates": _certificate_rows(kc),
|
|
92
|
+
"Endpoints": [_https_row(h) for h in _hosts(kc)],
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
def print_report(kc: str, namespaces: list[str], echo: Callable[[str], None] = print) -> bool:
|
|
97
|
+
"""Print the report; True when nothing is broken (⏳ items are fine)."""
|
|
98
|
+
report = build_report(kc, namespaces)
|
|
99
|
+
echo("\n🩺 PLATFORM HEALTH")
|
|
100
|
+
echo("=" * 60)
|
|
101
|
+
counts = {OK: 0, WAIT: 0, BAD: 0}
|
|
102
|
+
for section, rows in report.items():
|
|
103
|
+
if not rows:
|
|
104
|
+
continue
|
|
105
|
+
echo(f"\n{section}:")
|
|
106
|
+
for mark, name, detail in rows:
|
|
107
|
+
counts[mark] += 1
|
|
108
|
+
echo(f" {mark} {name:<45} {detail}")
|
|
109
|
+
echo("")
|
|
110
|
+
echo(f"{OK} {counts[OK]} ready {WAIT} {counts[WAIT]} settling {BAD} {counts[BAD]} broken")
|
|
111
|
+
if counts[WAIT]:
|
|
112
|
+
echo("⏳ items need no action: certificates and DNS can take from minutes to hours.")
|
|
113
|
+
echo(" Re-check any time with: f2dev check")
|
|
114
|
+
return counts[BAD] == 0
|
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Centralized logging setup for the CLI.
|
|
3
|
+
|
|
4
|
+
Design goals:
|
|
5
|
+
- One log file per ``cli.py`` launch, OVERWRITTEN (not appended) so
|
|
6
|
+
each run starts with a clean slate — easier to grep, easier to share
|
|
7
|
+
for debugging.
|
|
8
|
+
- Captures the ROOT logger so every Python log (click, urllib3,
|
|
9
|
+
subprocess, our deployers) lands in the same file.
|
|
10
|
+
- Also writes to stderr at INFO by default (``--verbose`` bumps to
|
|
11
|
+
DEBUG) so the user can see what's happening in real time.
|
|
12
|
+
- Default log path: ``/tmp/fast2dev-cli.log``. The existing
|
|
13
|
+
``--logging-file`` flag overrides it (for tests / CI / customer-
|
|
14
|
+
specific paths).
|
|
15
|
+
"""
|
|
16
|
+
|
|
17
|
+
from __future__ import annotations
|
|
18
|
+
|
|
19
|
+
import logging
|
|
20
|
+
import os
|
|
21
|
+
import sys
|
|
22
|
+
from datetime import datetime
|
|
23
|
+
from typing import Optional
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
# Default log file path. Overwritten on every launch. Can be overridden
|
|
27
|
+
# by setting the ``FAST2DEV_LOG_FILE`` env var or by passing a
|
|
28
|
+
# ``logging_file`` argument to :func:`setup_cli_logger` (which is what
|
|
29
|
+
# the existing ``--logging-file`` flag does).
|
|
30
|
+
DEFAULT_LOG_FILE_PREFIX = "/tmp/fast2dev-cli"
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def _default_log_file() -> str:
|
|
34
|
+
"""Build a timestamped log file name.
|
|
35
|
+
|
|
36
|
+
Each ``cli.py`` launch gets a unique file like
|
|
37
|
+
``/tmp/fast2dev-cli-2026-08-13-09-47-15.log`` so a previous
|
|
38
|
+
run's transcript isn't overwritten. The user can still set
|
|
39
|
+
``FAST2DEV_LOG_FILE`` or pass ``--logging-file`` to override.
|
|
40
|
+
"""
|
|
41
|
+
from datetime import datetime as _dt
|
|
42
|
+
return f"{DEFAULT_LOG_FILE_PREFIX}-{_dt.now().strftime('%Y-%m-%d-%H-%M-%S')}.log"
|
|
43
|
+
_LOGGER_NAME = "fast2dev_cli"
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
def _build_formatter(verbose: bool = False) -> logging.Formatter:
|
|
47
|
+
"""Standard formatter for the CLI log file.
|
|
48
|
+
|
|
49
|
+
Includes timestamp, level, logger name, and the message. In verbose
|
|
50
|
+
mode the timestamp includes milliseconds so multiple events on the
|
|
51
|
+
same second can be told apart.
|
|
52
|
+
"""
|
|
53
|
+
fmt = "%(asctime)s.%(msecs)03d [%(levelname)s] %(name)s: %(message)s" if verbose \
|
|
54
|
+
else "%(asctime)s [%(levelname)s] %(name)s: %(message)s"
|
|
55
|
+
return logging.Formatter(
|
|
56
|
+
fmt=fmt,
|
|
57
|
+
datefmt="%Y-%m-%d %H:%M:%S",
|
|
58
|
+
)
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
def setup_cli_logger(
|
|
62
|
+
logging_file: Optional[str] = None,
|
|
63
|
+
verbose: bool = False,
|
|
64
|
+
) -> logging.Logger:
|
|
65
|
+
"""Initialize the CLI logging subsystem.
|
|
66
|
+
|
|
67
|
+
Sets up the ROOT logger so every Python log lands in the same file.
|
|
68
|
+
Returns the ``fast2dev_cli`` logger so callers can also use it
|
|
69
|
+
directly for their own messages.
|
|
70
|
+
|
|
71
|
+
The log file is OVERWRITTEN (mode ``"w"``) on every call so each
|
|
72
|
+
``cli.py`` launch starts with a clean file.
|
|
73
|
+
|
|
74
|
+
Parameters
|
|
75
|
+
----------
|
|
76
|
+
logging_file : str, optional
|
|
77
|
+
Path to the log file. Defaults to ``$FAST2DEV_LOG_FILE`` if
|
|
78
|
+
set, otherwise ``/tmp/fast2dev-cli.log``.
|
|
79
|
+
verbose : bool
|
|
80
|
+
If True, the console handler logs at DEBUG; otherwise INFO.
|
|
81
|
+
The file handler always logs at DEBUG so the file has the
|
|
82
|
+
full transcript regardless of what the user sees.
|
|
83
|
+
"""
|
|
84
|
+
log_path = (
|
|
85
|
+
logging_file
|
|
86
|
+
or os.environ.get("FAST2DEV_LOG_FILE")
|
|
87
|
+
or _default_log_file()
|
|
88
|
+
)
|
|
89
|
+
|
|
90
|
+
# 1) Root logger — captures everything (urllib3, click, our code).
|
|
91
|
+
# level=DEBUG so the file has the full transcript.
|
|
92
|
+
root_logger = logging.getLogger()
|
|
93
|
+
root_logger.setLevel(logging.DEBUG)
|
|
94
|
+
|
|
95
|
+
# Clear any existing handlers (idempotent re-runs in the same
|
|
96
|
+
# process — important because the bootstrap calls this before
|
|
97
|
+
# the re-exec dance and again after it).
|
|
98
|
+
for handler in root_logger.handlers[:]:
|
|
99
|
+
root_logger.removeHandler(handler)
|
|
100
|
+
|
|
101
|
+
# 2) File handler — OVERWRITES the file each launch.
|
|
102
|
+
try:
|
|
103
|
+
file_handler = logging.FileHandler(log_path, mode="w", encoding="utf-8")
|
|
104
|
+
file_handler.setLevel(logging.DEBUG)
|
|
105
|
+
file_handler.setFormatter(_build_formatter(verbose=True))
|
|
106
|
+
root_logger.addHandler(file_handler)
|
|
107
|
+
except OSError as exc:
|
|
108
|
+
# If the user passed a bad path, fall back to /tmp and keep
|
|
109
|
+
# going — better to log somewhere than nowhere.
|
|
110
|
+
print(f"[fast2dev] WARNING: cannot open log file {log_path!r}: {exc}. "
|
|
111
|
+
f"Falling back to {DEFAULT_LOG_FILE_PREFIX}-<ts>.log.", file=sys.stderr)
|
|
112
|
+
file_handler = logging.FileHandler(DEFAULT_LOG_FILE_PREFIX, mode="w", encoding="utf-8")
|
|
113
|
+
file_handler.setLevel(logging.DEBUG)
|
|
114
|
+
file_handler.setFormatter(_build_formatter(verbose=True))
|
|
115
|
+
root_logger.addHandler(file_handler)
|
|
116
|
+
log_path = DEFAULT_LOG_FILE
|
|
117
|
+
|
|
118
|
+
# 3) Console handler — INFO by default, DEBUG with --verbose.
|
|
119
|
+
# Goes to stderr so it doesn't interfere with the click output.
|
|
120
|
+
console_handler = logging.StreamHandler(sys.stderr)
|
|
121
|
+
console_handler.setLevel(logging.DEBUG if verbose else logging.INFO)
|
|
122
|
+
console_handler.setFormatter(_build_formatter(verbose=False))
|
|
123
|
+
root_logger.addHandler(console_handler)
|
|
124
|
+
|
|
125
|
+
# 4) Library loggers — quiet down chatty ones unless verbose.
|
|
126
|
+
# We still want them to flow through the root handler so they
|
|
127
|
+
# end up in the log file; we just don't want to flood stderr.
|
|
128
|
+
if not verbose:
|
|
129
|
+
logging.getLogger("urllib3").setLevel(logging.WARNING)
|
|
130
|
+
logging.getLogger("google.auth").setLevel(logging.WARNING)
|
|
131
|
+
logging.getLogger("google.cloud").setLevel(logging.WARNING)
|
|
132
|
+
logging.getLogger("kubernetes").setLevel(logging.WARNING)
|
|
133
|
+
|
|
134
|
+
# 5) Banner — at DEBUG so it shows in the file always, but only
|
|
135
|
+
# on stderr when --verbose is set (default stderr is INFO).
|
|
136
|
+
logger = logging.getLogger(_LOGGER_NAME)
|
|
137
|
+
logger.debug("=" * 80)
|
|
138
|
+
logger.debug("Fast2.Dev Platform Deployment CLI Started")
|
|
139
|
+
logger.debug("All wizard steps, deployer calls, and errors are "
|
|
140
|
+
"logged to this file.")
|
|
141
|
+
logger.debug(f"Timestamp: {datetime.now().isoformat()}")
|
|
142
|
+
logger.debug(f"Log file: {log_path} (mode='w' = overwrite)")
|
|
143
|
+
logger.debug(f"Verbose: {verbose}")
|
|
144
|
+
logger.debug(f"Python: {sys.version.split()[0]} ({sys.executable})")
|
|
145
|
+
logger.debug(f"CWD: {os.getcwd()}")
|
|
146
|
+
logger.debug("=" * 80)
|
|
147
|
+
# The file-path hint only shows with --verbose (single line).
|
|
148
|
+
logger.debug(f"[fast2dev] log file: {log_path}")
|
|
149
|
+
|
|
150
|
+
# Also stash on a module-level global so the bootstrap can read it.
|
|
151
|
+
global _log_path
|
|
152
|
+
_log_path = log_path
|
|
153
|
+
return logger
|
|
154
|
+
|
|
155
|
+
|
|
156
|
+
# Standard "mode" icons used by :func:`log_step` so wizard / deployer
|
|
157
|
+
# progress is easy to grep visually. Mapping is short by design so
|
|
158
|
+
# log lines stay one-line-readable.
|
|
159
|
+
_ICONS = {
|
|
160
|
+
"ok": "✅",
|
|
161
|
+
"fail": "❌",
|
|
162
|
+
"warn": "⚠️ ",
|
|
163
|
+
"info": "ℹ️ ",
|
|
164
|
+
"step": "▶",
|
|
165
|
+
"wait": "⏳",
|
|
166
|
+
"rocket": "🚀",
|
|
167
|
+
"lock": "🔒",
|
|
168
|
+
"sh": "🛡️ ", # shield
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
def log_step(kind: str, message: str, *, level: int = logging.INFO) -> None:
|
|
173
|
+
"""Log a single wizard / deployer step with a mode icon prefix.
|
|
174
|
+
|
|
175
|
+
``kind`` is one of: ``ok``, ``fail``, ``warn``, ``info``,
|
|
176
|
+
``step``, ``wait``, ``rocket``, ``lock``, ``sh`` — or any
|
|
177
|
+
other string (used verbatim as the prefix).
|
|
178
|
+
"""
|
|
179
|
+
icon = _ICONS.get(kind, f"[{kind}]")
|
|
180
|
+
logging.getLogger(_LOGGER_NAME).log(level, f"{icon} {message}")
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
# Module-level state — set by setup_cli_logger.
|
|
184
|
+
_log_path: Optional[str] = None
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
def configure_terragrunt_cache() -> None:
|
|
188
|
+
"""Configure ``TG_DOWNLOAD_DIR`` to a short path to avoid Windows long-path issues.
|
|
189
|
+
|
|
190
|
+
Without this, Terragrunt on Windows can produce ``.terraform`` paths
|
|
191
|
+
that exceed the 260-character MAX_PATH limit. We set a short, fixed
|
|
192
|
+
path (``/tmp/terragrunt-cache`` on Linux/macOS, ``C:\\temp\\terragrunt-cache``
|
|
193
|
+
on Windows) and create the directory if it doesn't exist.
|
|
194
|
+
"""
|
|
195
|
+
if not os.environ.get("TG_DOWNLOAD_DIR"):
|
|
196
|
+
import platform
|
|
197
|
+
system = platform.system().lower()
|
|
198
|
+
if system == "windows":
|
|
199
|
+
cache_path = r"C:\temp\terragrunt-cache"
|
|
200
|
+
else:
|
|
201
|
+
cache_path = "/tmp/terragrunt-cache"
|
|
202
|
+
os.environ["TG_DOWNLOAD_DIR"] = cache_path
|
|
203
|
+
try:
|
|
204
|
+
os.makedirs(cache_path, exist_ok=True)
|
|
205
|
+
except OSError:
|
|
206
|
+
pass
|