Skip to content

Commit

Permalink
Database table structure
Browse files Browse the repository at this point in the history
  • Loading branch information
SimoneLazzaris authored Oct 24, 2017
1 parent 680fdd7 commit 241e707
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 0 deletions.
11 changes: 11 additions & 0 deletions polka.cf
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
port=9093
bind=127.0.0.1
defaultquota=500
dbuser=polka
dbpass=verysecretpassword
dbhost=127.0.0.1
dbport=3306
dbname=policy
badmailfrom_table=badmailfrom
badmailto_table=badmailto
policy_table=relay_policy
20 changes: 20 additions & 0 deletions table_structure.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
CREATE TABLE `badmailfrom` (
`sender` char(80) NOT NULL,
PRIMARY KEY (`sender`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

CREATE TABLE `badmailto` (
`rcpt` char(80) NOT NULL,
PRIMARY KEY (`rcpt`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

CREATE TABLE `relay_policy` (
`type` char(1) NOT NULL DEFAULT '',
`item` char(80) NOT NULL DEFAULT '',
`max` int(5) DEFAULT NULL,
`quota` float DEFAULT NULL,
`ts` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
PRIMARY KEY (`type`,`item`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;


0 comments on commit 241e707

Please sign in to comment.