Installing W3C's Unicorn Validator

Hi all,

As most of you are I’m sure aware, the W3C launched a new, all-in-one validator called Unicorn around this time last year. If you weren’t aware, here’s a quick summary:

Here it is if you’d like to check it out: Unicorn

The W3C encourages developers to download and extend this software, something I intend on doing. The problem is, the installation documentation is absolute gobbledygook to me, and when I showed it to the “installation team” at the company that controls my VPS, they had a similar reaction.

They did try and install an instance of it, but were greeted with the following error:


/usr/local/ant/bin/ant retrieve default_conf war
Buildfile: /usr/local/src/unicorn/build.xml

retrieve:

BUILD FAILED
/usr/local/src/unicorn/build.xml:18: Problem: failed to create task or type antlib:org.apache.ivy.ant:retrieve
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any / declarations have taken place.
No types or tasks have been defined in this namespace yet

This appears to be an antlib declaration. 
Action: Check that the implementing library exists in one of:
-/usr/local/ant/lib
-/root/.ant/lib
-a directory added on the command line with the -lib argument

Can anyone help with installing an instance of this software on my VPS? It seems far more complex than it should be.

Any help would be appreciated. Thanks!

you have to install ivy first

Installation | Apache Ivy�

Hi jurn, thanks for your response.

So can you confirm I’d able to install an instance of this on my VPS, and that the only thing holding me back is the lack of Apache Ivy? Are there any other common requirements that don’t come as standard on an Apache web server?

hi Alecrust,

Well, we got up to the part about ivy. After that is successful you should see output like below, indicating that “unicorn.war” has been created.

generate_observer:
  [xmlbean] Time to build schema type system: 1.047 seconds
  [xmlbean] Time to generate code: 0.729 seconds
  [xmlbean] Compiling 154 source files to /tmp/xbean2394721114190854444.d/classes
  [xmlbean] Time to compile code: 5.115 seconds
  [xmlbean] Building jar: /home/jurn/unicorn/lib/unicorn-response.jar

generate_tasklist:
  [xmlbean] Time to build schema type system: 0.812 seconds
  [xmlbean] Time to generate code: 0.08 seconds
  [xmlbean] Compiling 36 source files to /tmp/xbean8979610489912046368.d/classes
  [xmlbean] Time to compile code: 1.639 seconds
  [xmlbean] Building jar: /home/jurn/unicorn/lib/unicorn-tasklist.jar

compile:
    [javac] Compiling 101 source files to /home/jurn/unicorn/build/classes

war:
    [mkdir] Created dir: /home/jurn/unicorn/dist
    [mkdir] Created dir: /home/jurn/unicorn/build/medias
      [war] Building war: /home/jurn/unicorn/dist/unicorn.war

The next step is to deploy the webapp (unicorn.war) somewhere. You’ll need apache tomcat (or another java web container) to run it.

Jurn

actually, you might not need tomcat. you can build a jar file instead using:

ant cli

and then run the command line client.

Many thanks, I’ll give that a try!

Hmm, it seems Ivy is not available to download. When the install command is run:


Not Found

The requested URL /ivy/history/2.2.0/download.html was not found on this server.

oh hmm the footer link is broken :wink:
try this link instead
Download | Apache Ivy �

Many thanks jurn, looks like the build was successful and I have an instance of Unicorn running.

The last step in this process is assigning this software to an account within my VPS so that I can access it/see an instance of it running.

From speaking to my VPS provider they seem again confused by this, saying that once the build is successful on the server “that’s it” and it cannot be installed on a particular account.

So I’m left with no URL to view my instance of Unicorn and no cPanel account that I can setup FTP access for development etc.

Any help in this last stage would be appreciated!

I think you’ll need to

  1. setup tomcat first,
  2. and then deploy the war file in there.

I’m unsure about your VPS / network / account so can’t really comment, but try to get tomcat up and running first.