docker部署整理 ssl禁用

This commit is contained in:
xxqfamous 2023-05-25 17:45:03 +08:00
parent 38458764b4
commit 3f9a3aacfa
2 changed files with 3 additions and 1 deletions

View File

@ -7,6 +7,7 @@ default: &default
username: <%= ENV.fetch("MYSQL_USER") { 'root' } %>
password: <%= ENV.fetch("MYSQL_PWD") { '123456' } %>
wait_timeout: 10
ssl_mode: disabled
gitea_server:
adapter: mysql2
database: <%= ENV.fetch("MYSQL_DB_GITEA") { 'gitea' } %>
@ -14,6 +15,7 @@ default: &default
username: <%= ENV.fetch("MYSQL_USER") { 'root' } %>
password: <%= ENV.fetch("MYSQL_PWD") { '123456' } %>
encoding: utf8
ssl_mode: disabled
development:
<<: *default

View File

@ -14,7 +14,7 @@ namespace :sync_table_structure do
puts "bash: mysql -u#{database_username} -p#{database_password} -P#{database_port} -h#{database_host} #{database}"
system "mysql -u#{database_username} -p#{database_password} -P#{database_port} -h#{database_host} #{database} < #{Rails.root}/db/structure.sql"
system "mysql --ssl-mode='DISABLED' -u#{database_username} -p#{database_password} -P#{database_port} -h#{database_host} #{database} < #{Rails.root}/db/structure.sql"
puts "init success"
end