Skip to content

Commit

Permalink
Merge pull request #48 from maevsi/fix/trigger
Browse files Browse the repository at this point in the history
fix(contact): revert trigger creation
  • Loading branch information
dargmuesli authored Nov 20, 2023
2 parents 2bfb5a1 + 2ea3f75 commit 25acee0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
##############################
FROM sqitch/sqitch@sha256:acd47c19ba4cb1005eaeb17500c6236d462559dc7b2acfdf68d955adb72ed122 AS development
FROM sqitch/sqitch:v1.4.0.2 AS development

WORKDIR /srv/app

Expand All @@ -10,7 +10,7 @@ CMD ["sqitch", "--chdir", "src", "deploy", "&&", "sleep", "infinity"]


###########################
FROM postgres:16.1@sha256:a3a4524686403f8c29447a52dea7452923c1bb5d26b33793b93b5e703cd508a4 AS build
FROM postgres:16.1 AS build

ENV POSTGRES_DB=maevsi
ENV POSTGRES_PASSWORD=postgres
Expand All @@ -30,7 +30,7 @@ RUN export SQITCH_TARGET="$(cat SQITCH_TARGET.env)" \
&& pg_dump -s -h localhost -U postgres -p 5432 maevsi | sed -e '/^-- Dumped/d' > schema.sql

##############################
FROM alpine:3.18.4@sha256:eece025e432126ce23f223450a0326fbebde39cdf496a85d8c016293fc851978 AS validate
FROM alpine:3.18.4 AS validate

WORKDIR /srv/app

Expand All @@ -41,7 +41,7 @@ RUN diff schema.definition.sql schema.sql


##############################
FROM sqitch/sqitch@sha256:acd47c19ba4cb1005eaeb17500c6236d462559dc7b2acfdf68d955adb72ed122 AS production
FROM sqitch/sqitch:v1.4.0.2 AS production

ENV ENV=production

Expand Down
4 changes: 4 additions & 0 deletions src/revert/table_contact.sql
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

BEGIN;

DROP TRIGGER maevsi_trigger_contact_update_account_id ON maevsi.contact;

DROP FUNCTION maevsi.trigger_contact_update_account_id;

DROP TABLE maevsi.contact;

COMMIT;

0 comments on commit 25acee0

Please sign in to comment.