View | Details | Raw Unified | Return to bug 144383 | Differences between
and this patch

Collapse All | Expand All

(-)poweradmin/Makefile (-8 / +10 lines)
Lines 6-13 Link Here
6
#
6
#
7
7
8
PORTNAME=	poweradmin
8
PORTNAME=	poweradmin
9
PORTVERSION=	2.1.3
9
PORTVERSION=	2.1.4
10
PORTREVISION=	1
11
CATEGORIES=	dns www
10
CATEGORIES=	dns www
12
MASTER_SITES=	https://www.poweradmin.org/download/
11
MASTER_SITES=	https://www.poweradmin.org/download/
13
EXTRACT_SUFX=	.tgz
12
EXTRACT_SUFX=	.tgz
Lines 15-26 Link Here
15
MAINTAINER=	eg@fbsd.lt
14
MAINTAINER=	eg@fbsd.lt
16
COMMENT=	A set of PHP-scripts to manage PowerDNS over the web
15
COMMENT=	A set of PHP-scripts to manage PowerDNS over the web
17
16
18
USE_PHP=	gettext
17
USE_PHP=	gettext session
19
WANT_PHP_WEB=	yes
18
WANT_PHP_WEB=	yes
20
NO_BUILD=	yes
19
NO_BUILD=	yes
21
PEARDIR=	${PREFIX}/share/pear
20
PEARDIR=	${PREFIX}/share/pear
22
21
23
OPTIONS=	POSTGRESQL "Use PostgreSQL database instead of MySQL" off
22
OPTIONS=	MYSQL	"Use Mysql database support" on \
23
		PGSQL	"Use Pgsql database support" off
24
24
25
SUB_FILES=	pkg-message
25
SUB_FILES=	pkg-message
26
26
Lines 31-42 Link Here
31
31
32
.include <bsd.port.pre.mk>
32
.include <bsd.port.pre.mk>
33
33
34
.if defined(WITH_POSTGRESQL)
34
.if defined(WITH_MYSQL)
35
RUN_DEPENDS+=	${PEARDIR}/MDB2/Driver/pgsql.php:${PORTSDIR}/databases/pear-MDB2_Driver_pgsql
36
.else
37
RUN_DEPENDS+=	${PEARDIR}/MDB2/Driver/mysql.php:${PORTSDIR}/databases/pear-MDB2_Driver_mysql
35
RUN_DEPENDS+=	${PEARDIR}/MDB2/Driver/mysql.php:${PORTSDIR}/databases/pear-MDB2_Driver_mysql
38
.endif
36
.endif
39
37
38
.if defined(WITH_PGSQL)
39
RUN_DEPENDS+=	${PEARDIR}/MDB2/Driver/pgsql.php:${PORTSDIR}/databases/pear-MDB2_Driver_pgsql
40
.endif
41
40
post-extract:
42
post-extract:
41
	@cd ${WRKSRC} && ${RM} -rf "install"
43
	@cd ${WRKSRC} && ${RM} -rf "install"
42
44
Lines 65-71 Link Here
65
67
66
install-conf: install-app
68
install-conf: install-app
67
	cd ${WWWDIR}/${CFGDIR} ; \
69
	cd ${WWWDIR}/${CFGDIR} ; \
68
	${CHMOD} 0640 config-me.inc.php ; \
70
	${CHMOD} 0644 config-me.inc.php ; \
69
	if ${TEST} ! -f ${CFGFILE} ; then \
71
	if ${TEST} ! -f ${CFGFILE} ; then \
70
		${CP} -p config-me.inc.php ${CFGFILE} ; \
72
		${CP} -p config-me.inc.php ${CFGFILE} ; \
71
	fi
73
	fi
(-)poweradmin/distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
MD5 (poweradmin-2.1.3.tgz) = 3647703a40d6d8109f86f6b3cce0d310
1
MD5 (poweradmin-2.1.4.tgz) = 55b762bebc290bd1be061cb3363f976a
2
SHA256 (poweradmin-2.1.3.tgz) = 3cc545d0a8979ca6a60f3b41368f1bea827243b94ae7311c0c502f74ef25b2ac
2
SHA256 (poweradmin-2.1.4.tgz) = 46a13d4ce34444896ed95d265935fc7605aadc489f81214d545f8ee8a47137a1
3
SIZE (poweradmin-2.1.3.tgz) = 93541
3
SIZE (poweradmin-2.1.4.tgz) = 121052
(-)poweradmin/files/patch-docs-poweradmin-mysql-db-structure.sql (+80 lines)
Line 0 Link Here
1
--- docs/poweradmin-mysql-db-structure.sql.orig	2008-03-27 22:38:03.000000000 +0200
2
+++ docs/poweradmin-mysql-db-structure.sql	2010-03-24 13:05:07.000000000 +0200
3
@@ -1,4 +1,3 @@
4
-DROP TABLE IF EXISTS `users`;
5
 CREATE TABLE `users` (
6
   `id` int(11) NOT NULL auto_increment,
7
   `username` varchar(16) NOT NULL default '',
8
@@ -15,43 +14,39 @@
9
 INSERT INTO `users` VALUES (1,'admin','21232f297a57a5a743894a0e4a801fc3','Administrator','admin@example.net','Administrator with full rights.',1,1);
10
 UNLOCK TABLES;
11
 
12
-DROP TABLE IF EXISTS `perm_items`;
13
 CREATE TABLE `perm_items` (
14
   `id` int(11) NOT NULL auto_increment,
15
   `name` varchar(64) NOT NULL,
16
   `descr` text NOT NULL,
17
   PRIMARY KEY  (`id`)
18
-) ENGINE=MyISAM AUTO_INCREMENT=62 DEFAULT CHARSET=latin1;
19
+) ENGINE=MyISAM DEFAULT CHARSET=latin1;
20
 
21
 LOCK TABLES `perm_items` WRITE;
22
 INSERT INTO `perm_items` VALUES (41,'zone_master_add','User is allowed to add new master zones.'),(42,'zone_slave_add','User is allowed to add new slave zones.'),(43,'zone_content_view_own','User is allowed to see the content and meta data of zones he owns.'),(44,'zone_content_edit_own','User is allowed to edit the content of zones he owns.'),(45,'zone_meta_edit_own','User is allowed to edit the meta data of zones he owns.'),(46,'zone_content_view_others','User is allowed to see the content and meta data  of zones he does not own.'),(47,'zone_content_edit_others','User is allowed to edit the content of zones he does not own.'),(48,'zone_meta_edit_others','User is allowed to edit the meta data of zones he does not own.'),(49,'search','User is allowed to perform searches.'),(50,'supermaster_view','User is allowed to view supermasters.'),(51,'supermaster_add','User is allowed to add new supermasters.'),(52,'supermaster_edit','User is allowed to edit supermasters.'),(53,'user_is
0
_ueberuser','User has full access. God-like. Redeemer.'),(54,'user_view_others','User is allowed to see other users and their details.'),(55,'user_add_new','User is allowed to add new users.'),(56,'user_edit_own','User is allowed to edit their own details.'),(57,'user_edit_others','User is allowed to edit other users.'),(58,'user_passwd_edit_others','User is allowed to edit the password of other users.'),(59,'user_edit_templ_perm','User is allowed to change the permission template that is assigned to a us er.'),(60,'templ_perm_add','User is allowed to add new permission templates.'),(61,'templ_perm_edit','User is allowed to edit existing permission templates.');
23
_ueberuser','User has full access. God-like. Redeemer.'),(54,'user_view_others','User is allowed to see other users and their details.'),(55,'user_add_new','User is allowed to add new users.'),(56,'user_edit_own','User is allowed to edit their own details.'),(57,'user_edit_others','User is allowed to edit other users.'),(58,'user_passwd_edit_others','User is allowed to edit the password of other users.'),(59,'user_edit_templ_perm','User is allowed to change the permission template that is assigned to a us er.'),(60,'templ_perm_add','User is allowed to add new permission templates.'),(61,'templ_perm_edit','User is allowed to edit existing permission templates.');
24
 UNLOCK TABLES;
25
 
26
-DROP TABLE IF EXISTS `perm_templ`;
27
 CREATE TABLE `perm_templ` (
28
   `id` int(11) NOT NULL auto_increment,
29
   `name` varchar(128) NOT NULL,
30
   `descr` text NOT NULL,
31
   PRIMARY KEY  (`id`)
32
-) ENGINE=MyISAM AUTO_INCREMENT=5 DEFAULT CHARSET=latin1;
33
+) ENGINE=MyISAM DEFAULT CHARSET=latin1;
34
 
35
 LOCK TABLES `perm_templ` WRITE;
36
 INSERT INTO `perm_templ` VALUES (1,'Administrator','Administrator template with full rights.');
37
 UNLOCK TABLES;
38
 
39
-DROP TABLE IF EXISTS `perm_templ_items`;
40
 CREATE TABLE `perm_templ_items` (
41
   `id` int(11) NOT NULL auto_increment,
42
   `templ_id` int(11) NOT NULL,
43
   `perm_id` int(11) NOT NULL,
44
   PRIMARY KEY  (`id`)
45
-) ENGINE=MyISAM AUTO_INCREMENT=269 DEFAULT CHARSET=latin1;
46
+) ENGINE=MyISAM DEFAULT CHARSET=latin1;
47
 
48
 LOCK TABLES `perm_templ_items` WRITE;
49
-INSERT INTO `perm_templ_items` VALUES (249,1,53);
50
+INSERT INTO `perm_templ_items` VALUES (1,1,53);
51
 UNLOCK TABLES;
52
 
53
-DROP TABLE IF EXISTS `zones`;
54
 CREATE TABLE `zones` (
55
   `id` int(11) NOT NULL auto_increment,
56
   `domain_id` int(11) NOT NULL default '0',
57
@@ -59,4 +54,23 @@
58
   `comment` text,
59
   PRIMARY KEY  (`id`),
60
   KEY `owner` (`owner`)
61
-) ENGINE=MyISAM AUTO_INCREMENT=22001 DEFAULT CHARSET=latin1;
62
+) ENGINE=MyISAM DEFAULT CHARSET=latin1;
63
+
64
+CREATE TABLE zone_templ (
65
+  `id` int(11) NOT NULL auto_increment,
66
+  `name` varchar(128) NOT NULL,
67
+  `descr` text NOT NULL,
68
+  `owner` int(11) NOT NULL,
69
+  PRIMARY KEY (id)
70
+) ENGINE=MyISAM DEFAULT CHARSET=latin1;
71
+
72
+CREATE TABLE zone_templ_records (
73
+  `id` int(11) NOT NULL auto_increment,
74
+  `zone_templ_id` int(11) NOT NULL,
75
+  `name` varchar(255) NOT NULL,
76
+  `type` varchar(6) NOT NULL,
77
+  `content` varchar(255) NOT NULL,
78
+  `ttl` int(11) NOT NULL,
79
+  `prio` int(11) NOT NULL,
80
+  PRIMARY KEY (id)
81
+) ENGINE=MyISAM DEFAULT CHARSET=latin1;
(-)poweradmin/files/patch-poweradmin-pgsql-db-structure.sql (+24 lines)
Line 0 Link Here
1
--- docs/poweradmin-pgsql-db-structure.sql.orig	2008-03-30 22:22:56.000000000 +0300
2
+++ docs/poweradmin-pgsql-db-structure.sql	2010-03-24 13:04:59.000000000 +0200
3
@@ -63,3 +63,21 @@
4
 );
5
 
6
 CREATE INDEX zone_domain_owner ON zones(domain_id, owner);
7
+
8
+CREATE TABLE zone_templ (
9
+  id SERIAL PRIMARY KEY,
10
+  name varchar(128) NOT NULL,
11
+  descr text NOT NULL,
12
+  owner integer default 0
13
+);
14
+
15
+CREATE TABLE zone_templ_records (
16
+  id SERIAL PRIMARY KEY,
17
+  zone_templ_id integer NOT NULL,
18
+  name varchar(255) NOT NULL,
19
+  type varchar(6) NOT NULL,
20
+  content varchar(255) NOT NULL,
21
+  ttl integer default NULL,
22
+  prio integer default NULL 
23
+);
24
+
(-)poweradmin/files/patch-templates.inc.php (+11 lines)
Line 0 Link Here
1
--- inc/templates.inc.php.orig	2010-03-24 12:59:46.000000000 +0200
2
+++ inc/templates.inc.php	2010-03-24 13:00:01.000000000 +0200
3
@@ -193,7 +193,7 @@
4
 			while($r = $result->fetchRow()) {
5
 				// Call get_record_from_id for each row.
6
 				$ret[$retcount] = get_zone_templ_record_from_id($r["id"]);
7
-				$retcount;
8
+				$retcount++;
9
 			}
10
 			return $ret;
11
 		}

Return to bug 144383