#“Summary of Setting Up Your Own Private App Inventor Server For Your School”
It turns out that the setup of a private App Inventor server is easier than I thought. If you are used to Amazon EC2, it’ll be a doddle for you. The Google App Engine bit is absolutely trivial. Full MIT documentation is here.
- Go to appengine.google.com and sign-up with a GMail/GApps address.
- Create an App. This only means giving the App an name.You'll have to confirm your identity by SMS from Google. We used a variation of the name of our school as the app name so that our private App Inventor will be accessible at http://nameofourschool.appspot.com
- Download and install the latest Oracle/SUN JDKon your PC
- Download the App Engine Java SDK
- Unzip it to somewhere like c:\apps\appengine-java-sdk-1.6.1
- Download the latest App Inventor zip (currently Dec 20th 2011)
- Unzip
- Then un-gzip and un-tar theappinventor-Dec-20.tgz contained within. (Use 7-Zip for all these different archive formats if you are on a Windows PC)
- Navigate down into the the directory tree created by all this unzipping and copy the appinventor sub-directory you find so that it is at something like c:\apps\appinventor
- Now you need to setup a Build Server if you want to be able to download the Apps onto real phones. I did this on Amazon EC2
- Go to Amazon AWS and Sign-Up for a new account
- You will have to provide a Credit Card but it won't be charged
- You will be verified by an automated phone call
- Once the account is fully live, go to the AWS Console and make sure you are viewing EC2 instances in EU-West (Ireland)
- Create a new Amazon Linux AMI Micro 32-Bit Instance in Ireland using their new Quick Wizard. (Go for 32-bit to save hassle)
- This is free for a year so you don't have to worry about cost. Maybe a tenner a month after that?
- Grab the PEM SSH Key and do the usual messing to convert it to a Putty ppk file so that you can SSH to the instance.
- SSH to the instance
- Grab that App Inventor zip from Step 6 using wget on the EC2 instance
- Do all the unzipping etc again, but this time you want the other file contained within (for-BuildServer.tgz). Un-tar and un-gzip thatfor-BuildServer.tgz file
- I found that the OpenJDK that comes pre-configured on the Amazon Linux instances threw an error when I tried to build using it. So I installed the Oracle/SUN JDK instead
Go tohttp://www.oracle.com/technetwork/java/javase/downloads/jdk-7u2-download-1377129.html- It appears Java 1.7 has issues with signing the Apps. So you have to use the older 1.6 instead
- Go tohttp://www.oracle.com/technetwork/java/javase/downloads/jdk-6u30-download-1377139.html
- Download the 32-bit RPM bin for Linux using wget on the instance
- sudo sh thenameofthefile.rpm.bin
- sudo alternatives --install /usr/bin/java java /usr/java/latest/bin/java 1500
- sudo alternatives --set java /usr/java/latest/bin/java
- Now you can run the build server by going to the for-BuildServer directory you created in Step J above and just running./launch-buildserver
- In the AWS Console, Open up port 9990 in the security groups
- Copy the public DNS name of your server from the AWS console
- Now back on your Windows machine, go to c:\apps\appinventor\war\WEB-INF\appengine-web.xml
- Change localhost in<property name="build.server.host" value="localhost:9990" /> to the public DNS name of your build server
- Change<property name="use.whitelist" value="false"/> to be true
- Save the file
- Now editc:\apps\appinventor\war\whitelist and add the GMail/GApps addresses of every account that you are allowing to use this App Inventor instance. In our case that it me, 2 teachers and 30 pairs of kids, all using the school Parent's Association GApps email addresses that I created.
- In a Windows Command Prompt, cd to the c:\apps\appengine (or whatever) directory and then enter c:\apps\appengine-java-sdk-1.6.1\bin\appcfg.cmd -A myapplicationID update war (where myapplicationID is obviously the name you picked in Step 2)
- The last step builds and uploads App Inventor to App Engine and runs it. If, after a few minutes, you get a Success message then you are in business! Just go to http://nameofyourapp.appspot.com and you can login with your GMail/GApps account and start using App Inventor just like on the original Google site.
Shout if you have any questions or comments.
My next App Inventor post will be a status report on how the pilot in our school is going.