Changes between Version 16 and Version 17 of HowTo/WriteInstallScript

09/25/12 16:04:06 (9 years ago)



  • HowTo/WriteInstallScript

    v16 v17  
    9393##### Run Boot-time commands
    9494# Start my service -- assume it was installed at /usr/local/bin
    95 sudo /usr/local/bin/myproject-server
     95sudo /usr/local/bin/myproject-server   
     98= Upload your script =
     99In order for the Aggregate Manager to find and run the install script, you will need to upload your script in a web server that is publicly available. Most institution provide this service to their users. However if you don't have access in a web server in order to upload your script, you can setup a web server in GENI. Please follow [wiki:#InstallaWebServerinPlanetLab these instructions] about setting up a web server in a PlanetLab node.
    99101= 2. Test your script =
    104106== 3.b. Install a Web Server ==
    105107=== 3.b.i Use a PlanetLab Host ===
    106 = 4. Upload your script =
    107108= Useful tips =
     109== Install a Web Server in PlanetLab ==
     111=== Reserver a PlanetLab node ===
     112In order to install a web server in a PlanetLab node, it is better if you create a separate slice just for the web server and use the [attachment:plc-bbn-onenode.rspec attached rspec] to reserve a PlanetLab node. You can use either Omni or Flack to do this. If you are using Flack, then you can see [ this video] about how to create a slice with an existing rspec using Flack. While you follow the video make sure you also choose the `plc` manager so that you can reserver PlanetLab nodes.
     114=== Install and start a Web Server ===
     115Be patient, it might take up to 30-40 minutes for you sliver to be ready. Once your sliver is created you can login to your node. If you don't know how to login to your node you can follow [wiki:HowTo/LoginToNodes these instructions].
     117After you login :
     118  * install the apache server by running :
     119   {{{
     120sudo yum install -y httpd
     122   * modify the default port by running the following commande where <NEW_PORT> is the port you want to use:
     123   {{{
     124sudo sed 's/^Listen 80$/Listen <NEW_PORT>/' /etc/httpd/conf/httpd.conf |sudo tee /etc/httpd/conf/httpd.conf >/dev/null
     126   * start the web server :
     127   {{{
     128sudo /sbin/service httpd start
     130       If you get an error someone else might be using the port you used, change it again by using the following command where <OLD_PORT> is the port you used in the previous command:
     131    {{{
     132sudo sed 's/^Listen <OLD_PORT>$/Listen <NEW_PORT>/' /etc/httpd/conf/httpd.conf |sudo tee /etc/httpd/conf/httpd.conf >/dev/null