coolify/database/migrations
Andras Bacsai 68a9f2ca77 feat: add container restart tracking and crash loop detection
Track container restart counts from Docker and detect crash loops to provide better visibility into application health issues.

- Add restart_count, last_restart_at, and last_restart_type columns to applications table
- Detect restart count increases from Docker inspect data and send notifications
- Show restart count badge in UI with warning icon on Logs navigation
- Distinguish between crash restarts and manual restarts
- Implement 30-second grace period to prevent false "exited" status during crash loops
- Reset restart count on manual stop, restart, and redeploy actions
- Add unit tests for restart count tracking logic

This helps users quickly identify when containers are in crash loops and need attention, even when the container status flickers between states during Docker's restart backoff period.
2025-11-10 13:04:31 +01:00
..
2014_10_12_000000_create_users_table.php
2014_10_12_100000_create_password_reset_tokens_table.php
2014_10_12_200000_add_two_factor_columns_to_users_table.php
2018_08_08_100000_create_telescope_entries_table.php
2019_12_14_000001_create_personal_access_tokens_table.php
2023_03_20_112410_create_activity_log_table.php
2023_03_20_112411_add_event_column_to_activity_log_table.php
2023_03_20_112412_add_batch_uuid_column_to_activity_log_table.php
2023_03_20_112809_create_sessions_table.php
2023_03_20_112811_create_teams_table.php
2023_03_20_112812_create_team_user_table.php
2023_03_20_112813_create_team_invitations_table.php
2023_03_20_112814_create_instance_settings_table.php
2023_03_24_140711_create_servers_table.php
2023_03_24_140712_create_server_settings_table.php
2023_03_24_140853_create_private_keys_table.php
2023_03_27_075351_create_projects_table.php
2023_03_27_075443_create_project_settings_table.php
2023_03_27_075444_create_environments_table.php
2023_03_27_081716_create_applications_table.php
2023_03_27_081717_create_application_settings_table.php
2023_03_27_081718_create_application_previews_table.php
2023_03_27_083621_create_services_table.php
2023_03_27_085020_create_standalone_dockers_table.php
2023_03_27_085022_create_swarm_dockers_table.php
2023_03_28_062150_create_kubernetes_table.php
2023_03_28_083723_create_github_apps_table.php
2023_03_28_083726_create_gitlab_apps_table.php
2023_04_03_111012_create_local_persistent_volumes_table.php
2023_05_04_194548_create_environment_variables_table.php
2023_05_17_104039_create_failed_jobs_table.php
2023_05_24_083426_create_application_deployment_queues_table.php
2023_06_22_131459_move_wildcard_to_server.php
2023_06_23_084605_remove_wildcard_domain_from_instancesettings.php
2023_06_23_110548_next_channel_updates.php
2023_06_23_114131_change_env_var_value_length.php
2023_06_23_114132_remove_default_redirect_from_instance_settings.php
2023_06_23_114133_use_application_deployment_queues_as_activity.php
2023_06_23_114134_add_disk_usage_percentage_to_servers.php
2023_07_13_115117_create_subscriptions_table.php
2023_07_13_120719_create_webhooks_table.php
2023_07_13_120721_add_license_to_instance_settings.php
2023_07_27_182013_smtp_discord_schemaless_to_normal.php
2023_08_06_142951_add_description_field_to_applications_table.php
2023_08_06_142952_remove_foreignId_environment_variables.php
2023_08_06_142954_add_readonly_localpersistentvolumes.php
2023_08_07_073651_create_s3_storages_table.php
2023_08_07_142950_create_standalone_postgresqls_table.php
2023_08_08_150103_create_scheduled_database_backups_table.php
2023_08_10_113306_create_scheduled_database_backup_executions_table.php
2023_08_10_201311_add_backup_notifications_to_teams.php
2023_08_11_190528_add_dockerfile_to_applications_table.php
2023_08_15_095902_create_waitlists_table.php
2023_08_15_111125_update_users_table.php
2023_08_15_111126_update_servers_add_unreachable_count_table.php
2023_08_22_071048_add_boarding_to_teams.php
2023_08_22_071049_update_webhooks_type.php
2023_08_22_071050_update_subscriptions_stripe.php
2023_08_22_071051_add_stripe_plan_to_subscriptions.php
2023_08_22_071052_add_resend_as_email.php
2023_08_22_071053_add_resend_as_email_to_teams.php
2023_08_22_071054_add_stripe_reasons.php
2023_08_22_071055_add_discord_notifications_to_teams.php
2023_08_22_071056_update_telegram_notifications.php
2023_08_22_071057_add_nixpkgsarchive_to_applications.php
2023_08_22_071058_add_nixpkgsarchive_to_applications_remove.php
2023_08_22_071059_add_stripe_trial_ended.php
2023_08_22_071060_change_invitation_link_length.php
2023_09_20_082541_update_services_table.php
2023_09_20_082733_create_service_databases_table.php
2023_09_20_082737_create_service_applications_table.php
2023_09_20_083549_update_environment_variables_table.php
2023_09_22_185356_create_local_file_volumes_table.php
2023_09_23_111808_update_servers_with_cloudflared.php
2023_09_23_111809_remove_destination_from_services_table.php
2023_09_23_111811_update_service_applications_table.php
2023_09_23_111812_update_service_databases_table.php
2023_09_23_111813_update_users_databases_table.php
2023_09_23_111814_update_local_file_volumes_table.php
2023_09_23_111815_add_healthcheck_disable_to_apps_table.php
2023_09_23_111816_add_destination_to_services_table.php
2023_09_23_111817_use_instance_email_settings_by_default.php
2023_09_23_111818_set_notifications_on_by_default.php
2023_09_23_111819_add_server_emails.php
2023_10_08_111819_add_server_unreachable_count.php
2023_10_10_100320_update_s3_storages_table.php
2023_10_10_113144_add_dockerfile_location_applications_table.php
2023_10_12_132430_create_standalone_redis_table.php
2023_10_12_132431_add_standalone_redis_to_environment_variables_table.php
2023_10_12_132432_add_database_selection_to_backups.php
2023_10_18_072519_add_custom_labels_applications_table.php
2023_10_19_101331_create_standalone_mongodbs_table.php
2023_10_19_101332_add_standalone_mongodb_to_environment_variables_table.php
2023_10_24_103548_create_standalone_mysqls_table.php
2023_10_24_120523_create_standalone_mariadbs_table.php
2023_10_24_120524_add_standalone_mysql_to_environment_variables_table.php
2023_10_24_124934_add_is_shown_once_to_environment_variables_table.php
2023_11_01_100437_add_restart_to_deployment_queue.php
2023_11_07_123731_add_target_build_dockerfile.php
2023_11_08_112815_add_custom_config_standalone_postgresql.php
2023_11_09_133332_add_public_port_to_service_databases.php
2023_11_12_180605_change_fqdn_to_longer_field.php
2023_11_13_133059_add_sponsorship_disable.php
2023_11_14_103450_add_manual_webhook_secret.php
2023_11_14_121416_add_git_type.php
2023_11_16_101819_add_high_disk_usage_notification.php
2023_11_16_220647_add_log_drains.php
2023_11_17_160437_add_drain_log_enable_by_service.php
2023_11_20_094628_add_gpu_settings.php
2023_11_21_121920_add_additional_destinations_to_apps.php
2023_11_24_080341_add_docker_compose_location.php
2023_11_28_143533_add_fields_to_swarm_dockers.php
2023_11_29_075937_change_swarm_properties.php
2023_12_01_091723_save_logs_view_settings.php
2023_12_01_095356_add_custom_fluentd_config_for_logdrains.php
2023_12_08_162228_add_soft_delete_services.php
2023_12_11_103611_add_realtime_connection_problem.php
2023_12_13_110214_add_soft_deletes.php
2023_12_17_155616_add_custom_docker_compose_start_command.php
2023_12_18_093514_add_swarm_related_things.php
2023_12_19_124111_add_swarm_cluster_grouping.php
2023_12_30_134507_add_description_to_environments.php
2023_12_31_173041_create_scheduled_tasks_table.php
2024_01_01_231053_create_scheduled_task_executions_table.php
2024_01_02_113855_add_raw_compose_deployment.php
2024_01_12_123422_update_cpuset_limits.php
2024_01_15_084609_add_custom_dns_server.php
2024_01_16_115005_add_build_server_enable.php
2024_01_21_130328_add_docker_network_to_services.php
2024_01_23_095832_add_manual_webhook_secret_bitbucket.php
2024_01_23_113129_create_shared_environment_variables_table.php
2024_01_24_095449_add_concurrent_number_of_builds_per_server.php
2024_01_25_073212_add_server_id_to_queues.php
2024_01_27_164724_add_application_name_and_deployment_url_to_queue.php
2024_01_29_072322_change_env_variable_length.php
2024_01_29_145200_add_custom_docker_run_options.php
2024_02_01_111228_create_tags_table.php
2024_02_05_105215_add_destination_to_app_deployments.php
2024_02_06_132748_add_additional_destinations.php
2024_02_08_075523_add_post_deployment_to_applications.php
2024_02_08_112304_add_dynamic_timeout_for_deployments.php
2024_02_15_101921_add_consistent_application_container_name.php
2024_02_15_192025_add_is_gzip_enabled_to_services.php
2024_02_20_165045_add_permissions_to_github_app.php
2024_02_22_090900_add_only_this_server_deployment.php
2024_02_23_143119_add_custom_server_limits_to_teams_ultimate.php
2024_02_25_222150_add_server_force_disabled_field.php
2024_03_04_092244_add_gzip_enabled_and_stripprefix_settings.php
2024_03_07_115054_add_notifications_notification_disable.php
2024_03_08_180457_nullable_password.php
2024_03_11_150013_create_oauth_settings.php
2024_03_14_214402_add_multiline_envs.php
2024_03_18_101440_add_version_of_envs.php
2024_03_22_080914_remove_popup_notifications.php
2024_03_26_122110_remove_realtime_notifications.php
2024_03_28_114620_add_watch_paths_to_apps.php
2024_04_09_095517_make_custom_docker_commands_longer.php
2024_04_10_071920_create_standalone_keydbs_table.php
2024_04_10_082220_create_standalone_dragonflies_table.php
2024_04_10_091519_create_standalone_clickhouses_table.php
2024_04_10_124015_add_permission_local_file_volumes.php
2024_04_12_092337_add_config_hash_to_other_resources.php
2024_04_15_094703_add_literal_variables.php
2024_04_16_083919_add_service_type_on_creation.php
2024_04_17_132541_add_rollback_queues.php
2024_04_25_073615_add_docker_network_to_application_settings.php
2024_04_29_111956_add_custom_hc_indicator_apps.php
2024_05_06_093236_add_custom_name_to_application_settings.php
2024_05_07_124019_add_server_metrics.php
2024_05_10_085215_make_stripe_comment_longer.php
2024_05_15_091757_add_commit_message_to_app_deployment_queue.php
2024_05_15_151236_add_container_escape_toggle.php
2024_05_17_082012_add_env_sorting_toggle.php
2024_05_21_125739_add_scheduled_tasks_notification_to_teams.php
2024_05_22_103942_change_pre_post_deployment_commands_length_in_applications.php
2024_05_23_091713_add_gitea_webhook_to_applications.php
2024_06_05_101019_add_docker_compose_pr_domains.php
2024_06_06_103938_change_pr_issue_commend_id_type.php
2024_06_11_081614_add_www_non_www_redirect.php
2024_06_18_105948_move_server_metrics.php
2024_06_20_102551_add_server_api_sentinel.php
2024_06_21_143358_add_api_deployment_type.php
2024_06_22_081140_alter_instance_settings_add_instance_name.php
2024_06_25_184323_update_db.php
2024_07_01_115528_add_is_api_allowed_and_iplist.php
2024_07_05_120217_remove_unique_from_tag_names.php
2024_07_11_083719_application_compose_versions.php
2024_07_17_123828_add_is_container_labels_readonly.php
2024_07_18_110424_create_application_settings_is_preserve_repository_enabled.php
2024_07_18_123458_add_force_cleanup_server.php
2024_07_19_132617_disable_healtcheck_by_default.php
2024_07_23_112710_add_validation_logs_to_servers.php
2024_08_05_142659_add_update_frequency_settings.php
2024_08_07_155324_add_proxy_label_chooser.php
2024_08_09_215659_add_server_cleanup_fields_to_server_settings_table.php
2024_08_12_131659_add_local_file_volume_based_on_git.php
2024_08_12_155023_add_timezone_to_server_and_instance_settings.php
2024_08_14_183120_add_order_to_environment_variables_table.php
2024_08_15_115907_add_build_server_id_to_deployment_queue.php
2024_08_16_105649_add_custom_docker_options_to_dbs.php
2024_08_27_090528_add_compose_parsing_version_to_services.php
2024_09_05_085700_add_helper_version_to_instance_settings.php
2024_09_06_062534_change_server_cleanup_to_forced.php
2024_09_07_185402_change_cleanup_schedule.php
2024_09_08_130756_update_server_settings_default_timezone.php
2024_09_16_111428_encrypt_existing_private_keys.php
2024_09_17_111226_add_ssh_key_fingerprint_to_private_keys_table.php
2024_09_22_165240_add_advanced_options_to_cleanup_options_to_servers_settings_table.php
2024_09_26_083441_disable_api_by_default.php
2024_10_03_095427_add_dump_all_to_standalone_postgresqls.php
2024_10_10_081444_remove_constraint_from_service_applications_fqdn.php
2024_10_11_114331_add_required_env_variables.php
2024_10_14_090416_update_metrics_token_in_server_settings.php
2024_10_15_172139_add_is_shared_to_environment_variables.php
2024_10_16_120026_move_redis_password_to_envs.php
2024_10_16_192133_add_confirmation_settings_to_instance_settings_table.php
2024_10_17_093722_add_soft_delete_to_servers.php
2024_10_22_105745_add_server_disk_usage_threshold.php
2024_10_22_121223_add_server_disk_usage_notification.php
2024_10_29_093927_add_is_sentinel_debug_enabled_to_server_settings.php
2024_10_30_074601_rename_token_permissions.php
2024_11_02_213214_add_last_online_at_to_resources.php
2024_11_11_125335_add_custom_nginx_configuration_to_static.php
2024_11_11_125366_add_index_to_activity_log.php
2024_11_22_124742_add_uuid_to_environments_table.php
2024_12_05_091823_add_disable_build_cache_advanced_option.php
2024_12_05_212355_create_email_notification_settings_table.php
2024_12_05_212416_create_discord_notification_settings_table.php
2024_12_05_212440_create_telegram_notification_settings_table.php
2024_12_05_212546_migrate_email_notification_settings_from_teams_table.php
2024_12_05_212631_migrate_discord_notification_settings_from_teams_table.php
2024_12_05_212705_migrate_telegram_notification_settings_from_teams_table.php
2024_12_06_142014_create_slack_notification_settings_table.php
2024_12_09_105711_drop_waitlists_table.php
2024_12_10_122142_encrypt_instance_settings_email_columns.php
2024_12_10_122143_drop_resale_license.php
2024_12_11_135026_create_pushover_notification_settings_table.php
2024_12_11_161418_add_authentik_base_url_to_oauth_settings_table.php
2024_12_13_103007_encrypt_resend_api_key_in_instance_settings.php
2024_12_16_134437_add_resourceable_columns_to_environment_variables_table.php
2024_12_17_140637_add_server_disk_usage_check_frequency_to_server_settings_table.php
2024_12_23_142402_update_email_encryption_values.php
2025_01_05_050736_add_network_aliases_to_applications_table.php refactor(Application): rename network_aliases to custom_network_aliases across the application for clarity and consistency 2025-04-09 08:42:50 +02:00
2025_01_08_154008_switch_up_readonly_labels.php
2025_01_10_135244_add_horizon_job_details_to_queue.php
2025_01_13_130238_add_backup_retention_fields_to_scheduled_database_backups_table.php
2025_01_15_130416_create_docker_cleanup_executions_table.php
2025_01_16_110406_change_commit_message_to_text_in_application_deployment_queues.php
2025_01_16_130238_add_finished_at_to_executions_tables.php
2025_01_21_125205_update_finished_at_timestamps_if_not_set.php
2025_01_22_101105_remove_wrongly_created_envs.php
2025_01_27_102616_add_ssl_fields_to_database_tables.php
2025_01_27_153741_create_ssl_certificates_table.php
2025_01_30_125223_encrypt_local_file_volumes_fields.php
2025_02_27_125249_add_index_to_scheduled_task_executions.php
2025_03_01_112617_add_stripe_past_due.php
2025_03_14_140150_add_storage_deletion_tracking_to_backup_executions.php
2025_03_21_104103_disable_discord_here.php
2025_03_26_104103_disable_mongodb_ssl_by_default.php
2025_03_29_204400_revert_some_local_volume_encryption.php
2025_03_31_124212_add_specific_spa_configuration.php
2025_04_01_124212_stripe_comment_nullable.php fix(migrations): make stripe_comment field nullable in subscriptions table 2025-04-14 10:30:43 +02:00
2025_04_17_110026_add_application_http_basic_auth_fields.php refactor 2025-04-23 13:22:01 +02:00
2025_04_30_134146_add_is_migrated_to_services.php feat(migration): add 'is_migrated' and 'custom_type' columns to service_applications and service_databases tables 2025-04-30 16:43:59 +02:00
2025_05_26_100258_add_server_patch_notifications.php feat(server): implement server patch check notifications 2025-05-26 14:03:59 +02:00
2025_05_29_100258_add_terminal_enabled_to_server_settings.php feat(terminal-access): implement terminal access control for servers and containers, including UI updates and backend logic 2025-05-29 14:09:05 +02:00
2025_06_06_073345_create_server_previous_ip.php refactor(proxy-status): refactored how the proxy status is handled on the UI and on the backend 2025-06-06 14:47:54 +02:00
2025_06_16_123532_change_sentinel_on_by_default.php fix(migration): update default value handling for is_sentinel_enabled column in server_settings 2025-06-16 14:49:01 +02:00
2025_06_25_131350_add_is_sponsorship_popup_enabled_to_instance_settings_table.php feat(settings): add sponsorship popup toggle and corresponding database migration 2025-06-25 15:18:39 +02:00
2025_06_26_131350_optimize_activity_log_indexes.php fix: use correct property declaration for withinTransaction 2025-10-10 18:41:33 +02:00
2025_07_14_191016_add_deleted_at_to_application_previews_table.php feat(previews): implement soft delete and cleanup for ApplicationPreview, enhancing resource management in DeleteResourceJob 2025-07-14 21:17:40 +02:00
2025_07_16_202201_add_timeout_to_scheduled_database_backups_table.php fix(backups): large database backups are not working (#6217) 2025-07-18 15:47:14 +02:00
2025_08_07_142403_create_user_changelog_reads_table.php feat(changelog): implement automated changelog fetching from GitHub and enhance changelog read tracking 2025-08-12 10:07:11 +02:00
2025_08_17_102422_add_disable_local_backup_to_scheduled_database_backups_table.php feat(backup): add disable local backup option and related logic for S3 uploads 2025-08-17 12:34:20 +02:00
2025_08_18_104146_add_email_change_fields_to_users_table.php feat(email): implement email change request and verification process 2025-08-18 14:54:08 +02:00
2025_08_18_154244_change_env_sorting_default_to_false.php fix: disable env sorting by default 2025-08-18 17:47:21 +02:00
2025_08_21_080234_add_git_shallow_clone_to_application_settings_table.php feat(git-settings): add support for shallow cloning in application settings 2025-08-21 10:16:57 +02:00
2025_09_05_142446_add_pr_deployments_public_enabled_to_application_settings.php feat(settings): add option to restrict PR deployments to repository members and contributors 2025-09-05 14:30:51 +02:00
2025_09_10_172952_remove_is_readonly_from_local_persistent_volumes_table.php refactor(webhook): remove Webhook model and related logic; add migrations to drop webhooks and kubernetes tables 2025-09-10 19:35:53 +02:00
2025_09_10_173300_drop_webhooks_table.php refactor(webhook): remove Webhook model and related logic; add migrations to drop webhooks and kubernetes tables 2025-09-10 19:35:53 +02:00
2025_09_10_173402_drop_kubernetes_table.php refactor(webhook): remove Webhook model and related logic; add migrations to drop webhooks and kubernetes tables 2025-09-10 19:35:53 +02:00
2025_09_11_143432_remove_is_build_time_from_environment_variables_table.php refactor(environment): remove 'is_build_time' attribute from environment variable handling across the application to simplify configuration 2025-09-11 16:51:56 +02:00
2025_09_11_150344_add_is_buildtime_only_to_environment_variables_table.php feat(environment): introduce 'is_buildtime_only' attribute to environment variables for improved build-time configuration 2025-09-11 17:38:16 +02:00
2025_09_17_081112_add_use_build_secrets_to_application_settings.php feat(deployment): introduce 'use_build_secrets' setting for enhanced security during Docker builds and update related logic in deployment process 2025-09-17 10:34:38 +02:00
2025_09_18_080152_add_runtime_and_buildtime_to_environment_variables_table.php feat(environment): replace is_buildtime_only with is_runtime and is_buildtime flags for environment variables, updating related logic and views 2025-09-18 18:14:54 +02:00
2025_10_03_154100_update_clickhouse_image.php basics of adding / removing hetzner servers 2025-10-09 10:41:29 +02:00
2025_10_07_120723_add_s3_uploaded_to_scheduled_database_backup_executions_table.php feat(backup): enhance backup job with S3 upload handling and notifications 2025-10-07 15:02:23 +02:00
2025_10_08_181125_create_cloud_provider_tokens_table.php init of cloud providers 2025-10-08 20:47:50 +02:00
2025_10_08_185203_add_hetzner_server_id_to_servers_table.php basics of adding / removing hetzner servers 2025-10-09 10:41:29 +02:00
2025_10_09_095905_add_cloud_provider_token_id_to_servers_table.php improved hetzner features 2025-10-09 12:53:57 +02:00
2025_10_09_113602_add_hetzner_server_status_to_servers_table.php work work on hetzner integration 2025-10-09 16:54:13 +02:00
2025_10_09_125036_add_is_validating_to_servers_table.php work work on hetzner integration 2025-10-09 16:54:13 +02:00
2025_10_10_120000_create_cloud_init_scripts_table.php refactor: improve cloud-init script UX and remove description field 2025-10-11 11:16:28 +02:00
2025_10_10_120000_create_webhook_notification_settings_table.php fix: add missing server_patch_webhook_notifications field 2025-10-10 17:52:07 +02:00
2025_10_10_120001_populate_webhook_notification_settings_for_existing_teams.php fix: add missing server_patch_webhook_notifications field 2025-10-10 17:52:07 +02:00
2025_11_02_161923_add_dev_helper_version_to_instance_settings.php feat: add dev_helper_version to instance settings and update related functionality 2025-11-03 08:38:43 +01:00
2025_11_10_112500_add_restart_tracking_to_applications_table.php feat: add container restart tracking and crash loop detection 2025-11-10 13:04:31 +01:00