Posted in development on 07/16/2010 11:02 am by jwatson
I am making an assumption here that you already know the normal forward-usage of the patch command. If you’re unversed In case you didn’t want to decipher the entire man page just yet, you’re in luck. I came across an instance where I had to remove a previous patch file from the Magento Enterprise code-base. The patch was originally applied as so:
patch -p0 < firstpatch.patch
Problems ensued, and I was given a new patch, however it was a cumulative patch so it couldn’t be laid over the first patch. So how to remove? After a man-page reading, it’s quite a breeze. You need the original patch to be removed, and use the patch number you used in the first patching instance. In this case it equates to the following:
patch -R -p0 < firstpatch.patch
now you can add the new patch.
patch -p0 < secondpatch.patch
Hopefully this will save someone a man-page reading on a small terminal in a dimly lit server room.
Posted in development on 07/14/2010 03:00 pm by lmorroni
This small tutorial may seem overly simplified but I think that a lot of newbies out there will find it helpful. I also would consider using sbt instead of just maven but this tutorial covers just maven.
I have been developing using Lift for a little over a year now and I found the IDE choices grim. I tried Eclipse, Netbeans and IntelliJ. My clear favorite is IntelliJ. It does not specifically support the Lift Framework but it does have great support for Scala and Maven. Here’s how I set things up.
Download and Install Maven 2.2.1: http://maven.apache.org/download.html
You MUST set your M2_HOME environment variable. Methods to accomplish this vary from system to system.
Go to a directory where you want to create your Lift app and run something like this(varies depending on archetype)
1
2
3
4
5
6
7
| mvn archetype:generate -U \
-DarchetypeGroupId=net.liftweb \
-DarchetypeArtifactId=lift-archetype-basic \
-DarchetypeVersion=2.0 \
-DremoteRepositories=http://scala-tools.org/repo-releases \
-Dversion=0.1 \
-DgroupId=com.morroni.jagger -DartifactId=store-jagger |
Download and install intelliJ 9.02 Community Edition or Ultimate: http://www.jetbrains.com/idea/download/
Open up IntelliJ and goto the menu item IntelliJ->Preferences. Choose the Plugins menu on the left and click the Available tab at the top. Type “scala” to search for the relevant plugins. Highlight the Scala plugin and click the little disk/arrow icon to install them.

Open up IntelliJ and goto File->New Project
Choose Import project from external model and click Next

Choose Maven and click Next

Enter the location of the folder where you generated your maven project and click next

Select both profile radio boxes and click Next

Make sure the only Maven project available is selected and click Next

Click Finish.
When you are ready to run your project, right click on it and select Run “store-jagger [jetty:run]”

Open up a web browser and go to http://localhost:8080

Posted in Uncategorized on 04/29/2010 03:01 pm by lmorroni
I ran into this problem and got stuck on it for a day so I thought I would post. The only way to get PHP to talk to Microsoft SQL server properly on a Redhat/Centos 5.4 build is to ensure that you have disabled SELinux at start-up. This option is available from the install menu but can also be achieved by modifying the boot parameters.
Posted in Uncategorized, development on 03/24/2010 02:27 pm by lmorroni
Displaying a menu item only if a user is logged in. If they are not logged in, route them to /login
This is inside Boot.scala
1
2
3
4
| val LoggedIn = If(() => User.loggedIn_?, () => RedirectResponse("/login"))
val myLoc = Loc("SecurePage", "securePage" :: Nil, "Secure Page", LoggedIn)
val myMenu = Menu(myLoc)
val entries = myMenu ::Menu(Loc("Home", List("index"), "Home")) ::: User.sitemap |
Generate the api documents for a lift/scala project
Posted in support on 01/25/2010 05:08 pm by jwatson
You may receive trouble if you receive so much email that your quota of space on the mailserver goes beyond the limits. There are a few things you can do to stop this from happening, and if it is too late, you can recover some space and your email will begin functioning properly thereafter.
First off, you can set your email client to delete the messages from your trashcan when you close the application.
If you are running Mozilla Thunderbird:
1) Go to the Tools -> Account Settings from the menu.
2) Make sure your account is expanded in the left pane and Select “Server Settings” underneath your account.
3) Make sure you have checked “Empty Trash on Exit”. Now when you close your email client, it will automatically delete your trashed items and they will no longer be taking up space on the server.
Maybe your account is locked because you are already over quota? You can use the webmail interface to get into your email and delete large old messages.
1) go to <a href=”http://morronimail.com”>morronimail.com</a> and log in using your email user id and password.
2) click on the “size” label on the far right column of your email listings. this will sort your email by size. If if is not sorted largest to smallest, click on it again to attain this sort order.
3) you can click the checkbox on the left of your older and larger emails, especially those with attachments (PDF, Images, etc) that you no longer need. Click the delete option at the the top and it will place a strike-through font to all the emails you selected. Now click the purge emails option, and they will be permanently deleted, thus freeing space up on your account.
Posted in ecommerce on 01/25/2010 03:20 pm by jwatson
If you will be creating a web store, you will definitely need to setup a Merchant Account and a payment gateway. When creating a merchant account, it is a good practice to start with a bank you already work with. You can certainly shop around for better rates. For a payment gateway we recommend authorize.net
What to know for your Merchant Account application process:
1) If you have started development of your e-commerce site, get your merchant account under wraps as soon as possible. It takes time to work out a deal and even get approval from a bank, and if you are shopping around for the best deal, it will take even longer.
2) Know your products, and know your sales potential. You will need to offer the banks prospective sales numbers when negotiating the terms of your merchant account.
3) Be prepared to deal with fraud. Credit fraud happens. What will your recourse be if someone uses a stolen credit card through your e-commerce site? There are certainly steps to take to head this off. New sites most likely take advantage of better security measures such as Address Verification for the cardholder, as well as confirmation of CV2 codes. (the numbers on the back of your credit card)
Payment Gateways:
Payment gateways work through a secure encrypted route of communication between your e-commerce site and credit authorization services for validating transactions. They are a necessary safeguard against credit fraud. Additionally, you can use services through a payment gateway to process repeated billing cycles. This would be an additional plus if the services you are rendering are to be charged in some recurring basis.
With a merchant account and a proper payment gateway, you will be properly equipped to enter the e-commerce realm. If you are interested in more information on our e-commerce solutions, please contact us
Posted in operating systems, system admin on 01/21/2010 04:31 pm by jwatson
Perhaps SELinux was provided by default from your linux distribution of choice, or maybe it has been determined that it is not needed anymore for whatever applications the server is currently performing. Disabling SELinux is a matter of changing a line in your selinux config. The normal location would be to look in /etc/selinux/config and change the value of the SELINUX line.
# SELinux turned off
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
SELINUX=disabled
However, we’re not done yet! Before you reboot your system you need to make sure that your
kernel boot line isn’t expecting SELinux to be active. We can set it to be specifically deactivated as
follows:
with Grub:
edit your /boot/grub/menu.lst
title Ubuntu 9.04, kernel 2.6.28-11-generic
uuid 28cd3d96-e22c-4230-a63d-f7a73ec323e3
kernel /boot/vmlinuz-2.6.28-11-generic root=/dev/sda3 ro rootdelay=10 quiet splash selinux=0
initrd /boot/initrd.img-2.6.28-11-generic
quiet
Note: you may also need to add enforcing=0 to your kernel line, depending on your setup.
Posted in support on 01/08/2010 04:42 pm by jwatson
- You can download the latest version of Mozilla Thunderbird from this page:
http://www.mozilla.com/en-US/thunderbird
After the download completes, double click on the executable. It will start the install process. If a window appears asking you if you want to run the program, click “run”.
- You will see the intro screen to the installation proccess like so: simply click “next”

Installation intro screen
- Select Standard Install on the next screen and press next.

- Verify installation Location and click next

- Installation will proceed, make sure the “Launch Thunderbird” checkbox is checked and click finish to proceed.


- Now that the installation is complete, we can configure the email settings in the application. When thunderbird first starts up, you see this screen:
as you can see, I filled in my name, my email address and my password. press continue. Thunderbird will try and autodetect settings for you but we have to specify more information yet. Click continue.
Click Stop on this screen. We want to correct the information as follows. Click the Manual Setup button.
username is your supplied username for the system.
incoming: mailserver.morronimail.com , port 143, SSL/TLS
outgoing: smtpserver.morronimail.com, port 587, None

and the SMTP settings (which can be reached by clicking on outgoing smtp server on the left pane and then pressing “edit” or “add” if there is no selection

when you’re done with all the settings press ok and send yourself a test email. If you are prompted for your account password, enter it and select the box to remember the password. You’re set!
Posted in support on 01/08/2010 11:09 am by lmorroni
This short tutorial covers adding an e-mail account to Apple’s Mail Application. It includes specific information for Morroni technologies servers.
Goto Applications->Mail

Once Apple mail is open, goto the file menu item Mail->Preferences

Once inside Preferences, click on the Account tab at the top and fill in your user information. Click the + bottom in the bottom left of the screen.

This will bring up the new mail account wizard where you should insert your provided information.

Click Continue and you will be at step 2. Choose IMAP for Account Type. Enter a description of your choice. For incoming mail server use mailserver.morroni.com. Enter the user name and password provided to you.

Click continue. make sure to click Connect when you get the verify dialogue box (seen below).

The next screen sets up the outgoing mailserver. Use your provided login information and enter the fields as they are below.

Click Continue and again make sure to accept the verification of the security certificate.

Verify the information and click Create.
You are now done, enjoy your new setup!

