jamesrwhite / minicron

🕰️ Monitor your cron jobs
GNU General Public License v3.0
2.34k stars 154 forks source link

db setup error with postgresql #223

Closed sbstern closed 8 years ago

sbstern commented 8 years ago

When running db setup I am getting the following error: PG::WrongObjectType: ERROR: invalid locale name: "utf8_unicode_ci" : CREATE DATABASE "minicron" ENCODING = 'utf8' LC_COLLATE = 'utf8_unicode_ci'

I am trying to connect to an RDS postgresql db. Since it's on RDS I don't think I have the ability to add new locales or anything. Any advice here? I'm not the best with locales, but I think utf8_unicode_ci is a MySQL thing only though? Shouldn't it be en_US.UTF-8 for Postgres?

mgartner commented 8 years ago

I'm getting this with a local postgres database, on all versions of minicron. @jamesrwhite is there a workaround?

mgartner commented 8 years ago

In case it is helpful for anyone, I got around this bug by commenting out the lines that create the database: https://github.com/jamesrwhite/minicron/blob/73e7cec5bf47f4df7d8ff7f8864d3fe504f83699/lib/minicron/cli/commands.rb#L43-L49

jamesrwhite commented 8 years ago

I'll include the fix for this in the next release, thanks for reporting.

jamesrwhite commented 8 years ago

v0.9.6 is out now https://github.com/jamesrwhite/minicron/releases/tag/v0.9.6