Skip to content

Commit

Permalink
fix: open up CORS for dev
Browse files Browse the repository at this point in the history
  • Loading branch information
ZavenArra committed Oct 29, 2021
1 parent f3ce1bc commit 71906ab
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 6 deletions.
12 changes: 6 additions & 6 deletions database/migrations/sqls/20211018163418-createEarning-up.sql
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ CREATE TYPE currency_enum AS ENUM ('USD');

CREATE TABLE earnings
(
id uuid NOT NULL PRIMARY KEY,
worker_id uuid NOT NULL REFERENCES stakeholder.stakeholder(id),
contract_id uuid NOT NULL REFERENCES contract.contract(id),
funder_id uuid NOT NULL REFERENCES stakeholder.stakeholder(id),
id uuid NOT NULL DEFAULT uuid_generate_v4() PRIMARY KEY,
worker_id uuid NOT NULL,
contract_id uuid NOT NULL,
funder_id uuid NOT NULL,
amount numeric NOT NULL,
currency currency_enum NOT NULL,
calculated_at timestamptz NOT NULL,
Expand All @@ -18,10 +18,10 @@ CREATE TABLE earnings
payment_confirmation_id varchar,
payment_system varchar,
payment_confirmed_by uuid,
payment_confirmation_method confirmation_method_enum NOT NULL,
payment_confirmation_method confirmation_method_enum,
paid_at timestamptz,
payment_confirmed_at timestamptz,
status earning_status_enum NOT NULL,
active boolean NOT NULL,
active boolean DEFAULT true NOT NULL,
batch_id uuid REFERENCES batch(id)
);
1 change: 1 addition & 0 deletions deployment/overlays/development/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ bases:
- ../../base
patchesStrategicMerge:
- database-connection-sealed-secret.yaml
- mapping.yaml
11 changes: 11 additions & 0 deletions deployment/overlays/development/mapping.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
apiVersion: getambassador.io/v2
kind: Mapping
metadata:
name: treetracker-earnings-api
namespace: earnings
spec:
cors:
cors:
origins:
- '*'

0 comments on commit 71906ab

Please sign in to comment.