Requirements:
Database:
- Create the Drupal user in the database.
GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER ON drupal.* TO 'drupal'@'localhost' IDENTIFIED BY 'drupal';
Note: This is not secure and should only be used for demo. - Create a new database in mySQL called drupal.
create database drupal character set utf8;
Download and extract the quercus-3.2.1.war file.
jar -xvf quercus-3.2.1.war WEB-INFDrupal:
- Download and extract Drupal 6.9
- Copy the WEB-INF directory and files from the Quercus into the Drupal directory.
- Create a new project in NetBeans. Choose Java Web and Web Application with Existing Sources.
- Fill in the Name and location properties for the project.
Note: Please make sure that you choose a different folder for the project files. Please see the image below as an example. - Next select the application server, and set the Context Path. I renamed my context to /drupal
- Next select the Web Pages folder. This should be the top directory of the Drupal directory you extracted. This is the directory which contains index.php.
- Click Finish
- Open the project and navigate to the Web Pages folder. Navigate to the sites --> default directory. Right click on the default.settings.php file and copy. Paste the file back into the directory. Right click on the file it should be named something like default.settings_1.php, rename the file to settings.
Note: NetBeans will append the .php to the end of the file. - Right click on the project and select Properties. This will bring up the project properties. Select the Libraries Category. Here you will see the files that were included from Quercus 3.1.2 which were in the WEB-INF/lib directory.
- Click on Add Library and select MySQL JDBC Driver. Click OK.
- Finally Run Main Project (F6).
Drupal Configuration:
If you were successful, you should see the Drupal Configuration page.
- Select Install Drupal in English (You may choose differently based on your requirements).
- Fill in the database with the information we created earlier.
- Check mysqli
- Database Name: drupal
- Database Username : drupal
- Database Password: drupal
Click Save and Continue. - That will complete the database installation and bring up the Site Configuration Screen. Fill in the values and click Save and Continue.
- Finished. You should get an Installation Complete screen. Click on your new site.
Note: My installation has an error message because I don't have SMTP configured on my Mac.
Congratulations! You have Drupal 6.9 running on Quercus 3.1.2 on GlassFish 2.1.
4 comments :
John,
Have you tried Drupal with Domain Access - how do you work Drupal with Resin when Drupal is managing the various domains? Any thought or ideas would be welcome.
Thanks!
Hello Pachydermus,
I have not tried it with Domain access, nor multiple domains. I was simply trying to show that it was possible to use complex PHP based applications on Quercus. If I have further time, I will look at some of the more intricate details.
John
Thank you for providing this information. It worked like a charm.
I first tried to accomplish Drupal on Glassfish following instructions that used LRWPinJava on GlassFish. I gave up that attempt because the instructions assumed the OS for GlassFish was Solaris or Linux. It began to get too complicated to translate the installation of PHP and Drupal to my Windows XP environment.
I'm not sure why the author of that post recommended LRWPinJava. Your way is much simpler and seems to work just fine.
Thanks Barbara!
Post a Comment