|
From: <ric...@us...> - 2011-03-01 16:51:32
|
Revision: 5410
http://nhibernate.svn.sourceforge.net/nhibernate/?rev=5410&view=rev
Author: ricbrown
Date: 2011-03-01 16:51:25 +0000 (Tue, 01 Mar 2011)
Log Message:
-----------
Added installation instructions for PostgreSQL server.
Modified Paths:
--------------
trunk/nhibernate/src/NHibernate.TestDatabaseSetup/TestDatabaseSetup.cs
trunk/nhibernate/teamcity.build
Added Paths:
-----------
trunk/nhibernate/lib/teamcity/postgresql/postgresql_installation.txt
Added: trunk/nhibernate/lib/teamcity/postgresql/postgresql_installation.txt
===================================================================
--- trunk/nhibernate/lib/teamcity/postgresql/postgresql_installation.txt (rev 0)
+++ trunk/nhibernate/lib/teamcity/postgresql/postgresql_installation.txt 2011-03-01 16:51:25 UTC (rev 5410)
@@ -0,0 +1,16 @@
+
+Installation steps for PostgreSQL for NH TeamCity:
+
+1. Download PostgreSQL (postgresql-9.0.3-1-windows_x64.exe): http://www.enterprisedb.com/products-services-training/pgdownload#windows;
+2. Run the installer ... when prompted to make a password for the service account, make it 'password';
+3. Leave the port number at the default (5432), and leave the default locale;
+4. The setup should install PostgreSQL on the machine;
+5. Untick the option to install stack-builder at the end (it's not required).
+
+Creating the NH user:
+
+a. Open pgAdmin III (start -> programs -> PostgreSQL 9.0 -> pgAdmin III);
+b. right-click the PostgreSQL 9.0 database, select connect, and enter the password from step 2 above;
+c. right-clilck the Login Roles, and select "New Login Role ...";
+d. create a login with "Role name=nhibernate", "Password=nhibernate", and select Superuser on the Role privileges tab.
+
Modified: trunk/nhibernate/src/NHibernate.TestDatabaseSetup/TestDatabaseSetup.cs
===================================================================
--- trunk/nhibernate/src/NHibernate.TestDatabaseSetup/TestDatabaseSetup.cs 2011-03-01 05:55:17 UTC (rev 5409)
+++ trunk/nhibernate/src/NHibernate.TestDatabaseSetup/TestDatabaseSetup.cs 2011-03-01 16:51:25 UTC (rev 5410)
@@ -1,9 +1,10 @@
using System;
using System.Collections.Generic;
using System.Data.SqlClient;
+using System.IO;
+using FirebirdSql.Data.FirebirdClient;
using Npgsql;
using NUnit.Framework;
-using FirebirdSql.Data.FirebirdClient;
namespace NHibernate.TestDatabaseSetup
{
@@ -51,8 +52,9 @@
{
cmd.ExecuteNonQuery();
}
- catch(Exception)
+ catch(Exception e)
{
+ Console.WriteLine(e);
}
cmd.CommandText = "create database nhibernate";
@@ -63,6 +65,16 @@
private static void SetupFirebird(Cfg.Configuration cfg)
{
+ try
+ {
+ if (File.Exists("NHibernate.fdb"))
+ File.Delete("NHibernate.fdb");
+ }
+ catch (Exception e)
+ {
+ Console.WriteLine(e);
+ }
+
FbConnection.CreateDatabase("Database=NHibernate.fdb;ServerType=1");
}
@@ -82,8 +94,9 @@
{
cmd.ExecuteNonQuery();
}
- catch (Exception)
+ catch (Exception e)
{
+ Console.WriteLine(e);
}
cmd.CommandText = "create database nhibernate";
Modified: trunk/nhibernate/teamcity.build
===================================================================
--- trunk/nhibernate/teamcity.build 2011-03-01 05:55:17 UTC (rev 5409)
+++ trunk/nhibernate/teamcity.build 2011-03-01 16:51:25 UTC (rev 5410)
@@ -96,7 +96,7 @@
<property name="nunit.found" value="true" />
<property name="nhibernate.connection.driver_class" value="NHibernate.Driver.NpgsqlDriver" />
<property name="nhibernate.dialect" value="NHibernate.Dialect.PostgreSQL82Dialect" />
- <property name="nhibernate.connection.connection_string" value="Host=localhost;Port=5433;Database=nhibernate;Username=nhibernate;Password=nhdbpass" />
+ <property name="nhibernate.connection.connection_string" value="Host=localhost;Port=5432;Database=nhibernate;Username=nhibernate;Password=nhibernate" />
<copy todir="${bin.dir}">
<fileset basedir="${root.dir}/lib/teamcity/postgresql">
<include name="*.dll"/>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|