From 45119e5505f25db967c79c5e99739ed8e347fd4b Mon Sep 17 00:00:00 2001 From: andreaturli Date: Sun, 11 Sep 2011 00:37:18 +0100 Subject: [PATCH] issue 384: kickstart admin node on macosx -> complete --- .../virtualbox/experiment/FileServer.java | 47 ------------------- 1 file changed, 47 deletions(-) delete mode 100644 sandbox-apis/virtualbox/src/test/java/org/jclouds/virtualbox/experiment/FileServer.java diff --git a/sandbox-apis/virtualbox/src/test/java/org/jclouds/virtualbox/experiment/FileServer.java b/sandbox-apis/virtualbox/src/test/java/org/jclouds/virtualbox/experiment/FileServer.java deleted file mode 100644 index 2a1843a5bf..0000000000 --- a/sandbox-apis/virtualbox/src/test/java/org/jclouds/virtualbox/experiment/FileServer.java +++ /dev/null @@ -1,47 +0,0 @@ -/** - * Licensed to jclouds, Inc. (jclouds) under one or more - * contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. jclouds licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -package org.jclouds.virtualbox.experiment; - -import org.eclipse.jetty.server.Handler; -import org.eclipse.jetty.server.Server; -import org.eclipse.jetty.server.handler.DefaultHandler; -import org.eclipse.jetty.server.handler.HandlerList; -import org.eclipse.jetty.server.handler.ResourceHandler; -import org.eclipse.jetty.util.log.Log; - -public class FileServer { - public static void main(String[] args) throws Exception { - Server server = new Server(args.length == 0 ? 8080 : Integer.parseInt(args[0])); - - ResourceHandler resource_handler = new ResourceHandler(); - resource_handler.setDirectoriesListed(true); - resource_handler.setWelcomeFiles(new String[] { "index.html" }); - - resource_handler.setResourceBase(args.length == 2 ? args[1] : "."); - Log.info("serving " + resource_handler.getBaseResource()); - - HandlerList handlers = new HandlerList(); - handlers.setHandlers(new Handler[] { resource_handler, new DefaultHandler() }); - server.setHandler(handlers); - - server.start(); - server.join(); - } - -} \ No newline at end of file