#!/usr/bin/env bash set -euo pipefail mkdir -p /app/logs if [ ! -f /app/config.yaml ]; then cat > /app/config.yaml < /app/wechat_ipad/config.toml </dev/null fi service mariadb start service redis-server start mysql -uroot -e "CREATE DATABASE IF NOT EXISTS \`${DB_NAME}\` DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;" exec "$@"