2024-06-01 02:11:02 -06:00
|
|
|
<%= unless no_sql_user do %>
|
2018-12-16 09:25:31 -07:00
|
|
|
CREATE USER <%= dbuser %> WITH ENCRYPTED PASSWORD '<%= dbpass %>';
|
2024-06-01 02:11:02 -06:00
|
|
|
<% end %>
|
|
|
|
<%= unless no_db_creation do %>
|
|
|
|
CREATE DATABASE IF NOT EXISTS <%= dbname %> OWNER <%= dbuser %>;
|
|
|
|
<% end %>
|
2018-12-16 09:25:31 -07:00
|
|
|
\c <%= dbname %>;
|
2017-11-26 10:57:49 -07:00
|
|
|
--Extensions made by ecto.migrate that need superuser access
|
2017-12-03 16:06:05 -07:00
|
|
|
CREATE EXTENSION IF NOT EXISTS citext;
|
2018-05-16 09:55:20 -06:00
|
|
|
CREATE EXTENSION IF NOT EXISTS pg_trgm;
|
2018-12-02 03:20:49 -07:00
|
|
|
CREATE EXTENSION IF NOT EXISTS "uuid-ossp";
|
2019-06-22 03:54:16 -06:00
|
|
|
<%= if rum_enabled do
|
|
|
|
"CREATE EXTENSION IF NOT EXISTS rum;"
|
|
|
|
else
|
|
|
|
""
|
|
|
|
end %>
|