Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf: core 日志目录变更 #331

Merged
merged 1 commit into from
Jul 20, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions scripts/7_upgrade.sh
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,13 @@ function migrate_config_v1_5_to_v2_0() {
fi
}

function migrate_data_folder() {
volume_dir=$(get_config VOLUME_DIR)
if [[ -d "${volume_dir}/core/logs" ]] && [[ ! -d "${volume_dir}/core/data/logs" ]]; then
mv "${volume_dir}/core/logs" "${volume_dir}/core/data/logs"
fi
}

function migrate_config() {
prepare_config
}
Expand Down Expand Up @@ -198,6 +205,7 @@ function db_migrations() {
exit 1
fi
fi
migrate_data_folder
if ! perform_db_migrations; then
log_error "$(gettext 'Failed to change the table structure')!"
confirm="n"
Expand Down