First things first, so the first step was to import the project into CVS.
I decided to import it under the folder 'PasmaTaskLibraryProject\5_implementation\original_prototype' of the repository: '/home/gpasma-1/gpasma-1_valju_pasmaweb/repository'
Next step was to get rid of some word documents that were hanging around with the source files (they were already inside the 'doc' folder) and deleting all the .class files.
Finally to the fun part. After a quick look into the sources I concluded the previous project was using a database schema called 'prosessimalli' and logging in as root to the MySQL server.
Since I don't want to have my MySQL root account open like that I decided to create an unprivileged user called 'proto'.
For this I started my MySQL command line client, log in as root (locally) and issued the commands:
cd C:\Program Files\MySQL\MySQL Server 5.0\bin
mysql -u root -p
- Starts the mysql command line client
- Creates a new database
- This gives all privileges on the db 'prosessimalli' to my new user 'proto'
mysql -u proto -p prosessimalli < sql_lauseet.sql
mysql -u proto -p prosessimalli < insert_tehtava.sql
mysql -u proto -p prosessimalli < insert_tehtavatulos_1.sql
the names after the '<' simbol are the sql scritpts. The password for the user you just created will be asked before the script is run.
In case you are wondering why I used the command line, it is just because I don't have PHPMyAdmin, don't know how to use it and can't be bothered to learn...
Next step is to run the application. Since I had tomcat integrated to Eclipse via TomcatPlug-in (see tools of the trade post) I decide to use it. Here are the steps:
- Created a new Tomcat project called 'proto'
- Copied the .htm files to the project root
- Copied the business, tietokanta and WebGui folders to /web-inf/src
- Copied the jsp and lib folders and the web.xml file to /web-inf
- restarted Tomcat and accessed the URI: http://localhost:8080/proto/
Regular user: kirkas
pass: aurinko
Admin user: sininen
pass: meri
No comments:
Post a Comment