Skip to content

Commit

Permalink
Only create postgis extension if it isn't already enabled
Browse files Browse the repository at this point in the history
When using the mdillon/postgis docker image (also used by
docker/data/Dockerfile), the extension is already enabled.
  • Loading branch information
jszwedko committed Jul 16, 2018
1 parent 0642b49 commit 8bb5932
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion db/migrations/001_enable_postgis_extension.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Sequel.migration do
up do
execute %{ CREATE EXTENSION "postgis"; }
execute %{ CREATE EXTENSION IF NOT EXISTS "postgis"; }
end

down do
Expand Down

0 comments on commit 8bb5932

Please sign in to comment.