Commit 05a1a8f8 authored by David Johnson's avatar David Johnson

Generalize the CloudLab (OpenStack) tutorial.

(And add it to Emulab, POWDER, and Apt.)
parent 497b8677
...@@ -35,6 +35,7 @@ cloudlab: $(SOURCES) ...@@ -35,6 +35,7 @@ cloudlab: $(SOURCES)
cp -r $(GENI_LIB_DIR)/docs/build/html cloudlab-manual/geni-lib cp -r $(GENI_LIB_DIR)/docs/build/html cloudlab-manual/geni-lib
scribble --htmls ++style cloudlab-manual.css ++arg --clab ++arg --geni-lib-dir ++arg $(GENI_LIB_DIR) cloudlab-manual.scrbl scribble --htmls ++style cloudlab-manual.css ++arg --clab ++arg --geni-lib-dir ++arg $(GENI_LIB_DIR) cloudlab-manual.scrbl
scribble --html --dest cloudlab-manual/ ++style cloudlab-manual.css ++arg --single-page ++arg --clab ++arg --geni-lib-dir ++arg $(GENI_LIB_DIR) cloudlab-manual.scrbl scribble --html --dest cloudlab-manual/ ++style cloudlab-manual.css ++arg --single-page ++arg --clab ++arg --geni-lib-dir ++arg $(GENI_LIB_DIR) cloudlab-manual.scrbl
cd cloudlab-manual && ln -sf openstack-tutorial.html cloudlab-tutorial.html
cloudlab-ga: $(SOURCES) cloudlab-ga: $(SOURCES)
-mkdir cloudlab-manual/ -mkdir cloudlab-manual/
...@@ -42,6 +43,7 @@ cloudlab-ga: $(SOURCES) ...@@ -42,6 +43,7 @@ cloudlab-ga: $(SOURCES)
-rm -rf cloudlab-manual/geni-lib/ -rm -rf cloudlab-manual/geni-lib/
cp -r $(GENI_LIB_DIR)/docs/build/html cloudlab-manual/geni-lib cp -r $(GENI_LIB_DIR)/docs/build/html cloudlab-manual/geni-lib
scribble --htmls ++style cloudlab-manual.css ++arg --ga ++arg --clab ++arg --geni-lib-dir ++arg $(GENI_LIB_DIR) cloudlab-manual.scrbl scribble --htmls ++style cloudlab-manual.css ++arg --ga ++arg --clab ++arg --geni-lib-dir ++arg $(GENI_LIB_DIR) cloudlab-manual.scrbl
cd cloudlab-manual && ln -sf openstack-tutorial.html cloudlab-tutorial.html
phantomnet: $(SOURCES) phantomnet: $(SOURCES)
-mkdir phantomnet-manual/ -mkdir phantomnet-manual/
......
...@@ -68,4 +68,5 @@ of Utah. ...@@ -68,4 +68,5 @@ of Utah.
@include-section["advanced-topics.scrbl"] @include-section["advanced-topics.scrbl"]
@include-section["hardware.scrbl"] @include-section["hardware.scrbl"]
@include-section["planned.scrbl"] @include-section["planned.scrbl"]
@include-section["openstack-tutorial.scrbl"]
@include-section["getting-help.scrbl"] @include-section["getting-help.scrbl"]
...@@ -94,7 +94,7 @@ information about how they work. ...@@ -94,7 +94,7 @@ information about how they work.
running experiments. You can get back to this page at any time by running experiments. You can get back to this page at any time by
selecting the ``Start Experiment'' link from the ``Actions'' menu. selecting the ``Start Experiment'' link from the ``Actions'' menu.
By default, this page suggests launching the OpenStack profile which By default, this page suggests launching the OpenStack profile which
is discribed in detail in the @seclink["cloudlab-tutorial"]{OpenStack tutorial}. is discribed in detail in the @seclink["openstack-tutorial"]{OpenStack tutorial}.
Go to the list of available profile by clicking ``Change Profile'': Go to the list of available profile by clicking ``Change Profile'':
......
...@@ -54,6 +54,6 @@ control system can be found on CloudLab's @hyperlink[(apturl ...@@ -54,6 +54,6 @@ control system can be found on CloudLab's @hyperlink[(apturl
@include-section["advanced-topics.scrbl"] @include-section["advanced-topics.scrbl"]
@include-section["hardware.scrbl"] @include-section["hardware.scrbl"]
@include-section["planned.scrbl"] @include-section["planned.scrbl"]
@include-section["cloudlab-tutorial.scrbl"] @include-section["openstack-tutorial.scrbl"]
@include-section["cloudlab-chef-tutorial.scrbl"] @include-section["cloudlab-chef-tutorial.scrbl"]
@include-section["getting-help.scrbl"] @include-section["getting-help.scrbl"]
...@@ -74,6 +74,19 @@ ...@@ -74,6 +74,19 @@
(define (clab-only . stuff) (define (clab-only . stuff)
(apt-vs-clab #:clab stuff)) (apt-vs-clab #:clab stuff))
(define (geniusers-only . stuff)
(apt-vs-clab #:clab stuff #:powder stuff))
(define (not-clab . stuff)
(case (tb-mode)
('clab "")
(else stuff)))
(define (not-elab . stuff)
(case (tb-mode)
('elab "")
(else stuff)))
(define (pnet-only . stuff) (define (pnet-only . stuff)
(apt-vs-clab #:pnet stuff)) (apt-vs-clab #:pnet stuff))
...@@ -92,6 +105,15 @@ ...@@ -92,6 +105,15 @@
('clab "") ('clab "")
(else stuff))) (else stuff)))
(define (tb-specific #:apt [apt-version #f] #:clab [clab-version #f] #:pnet [pnet-version #f] #:powder [powder-version #f] #:elab [elab-version #f] #:default [default-version ""])
(decode-flow (list (case (tb-mode)
(('apt and apt-version) apt-version)
(('clab and clab-version) clab-version)
(('pnet and pnet-version) pnet-version)
(('powder and powder-version) powder-version)
(('elab and elab-version) elab-version)
(else default-version)))))
(define apt-base-url (define apt-base-url
(case (tb-mode) (case (tb-mode)
('apt "https://www.aptlab.net/") ('apt "https://www.aptlab.net/")
...@@ -100,6 +122,9 @@ ...@@ -100,6 +122,9 @@
('powder "https://www.powderwireless.net/") ('powder "https://www.powderwireless.net/")
('elab "https://www.emulab.net/portal/"))) ('elab "https://www.emulab.net/portal/")))
(define (apt-url path)
(string-append apt-base-url path))
(define apt-doc-url (define apt-doc-url
(case (tb-mode) (case (tb-mode)
('apt "http://docs.aptlab.net/") ('apt "http://docs.aptlab.net/")
...@@ -177,13 +202,31 @@ ...@@ -177,13 +202,31 @@
[scale-factor (* 1.0 (/ screenshot-width width))]) [scale-factor (* 1.0 (/ screenshot-width width))])
(list (image #:scale scale-factor fullpath fullpath) (linebreak)))) (list (image #:scale scale-factor fullpath fullpath) (linebreak))))
(define (instructionstep step #:screenshot [screenshot-path #f] . body) (define (any-screenshot where path)
(let* ([anypath (string-append "screenshots/" where "/" path)]
[fullpath (if (file-exists? anypath)
anypath
(cdr (cons (displayln (string-append "WARNING: missing '" where "'screenshot " path)) anypath)))]
[b (make-object bitmap% fullpath)]
[width (send b get-width)]
[scale-factor (* 1.0 (/ screenshot-width width))])
(list (image #:scale scale-factor fullpath fullpath) (linebreak))))
(define (common-screenshot path)
(any-screenshot "common" path))
(define (clab-screenshot path)
(any-screenshot "clab" path))
(define (instructionstep step #:screenshot [screenshot-path #f] #:screenshot-where [screenshot-where #f] . body)
(item (bold (decode-content (list step))) (item (bold (decode-content (list step)))
(linebreak) (linebreak)
(decode-flow body) (decode-flow body)
(if screenshot-path (if screenshot-where
(screenshot screenshot-path) (any-screenshot screenshot-where screenshot-path)
(void)))) (if screenshot-path
(screenshot screenshot-path)
(void)))))
(define (read-sphinx-inventory directory) (define (read-sphinx-inventory directory)
(let ([inv-file (string-append directory "/objects.inv")]) (let ([inv-file (string-append directory "/objects.inv")])
......
...@@ -48,4 +48,5 @@ you can apply to start a new project. ...@@ -48,4 +48,5 @@ you can apply to start a new project.
@include-section["advanced-topics.scrbl"] @include-section["advanced-topics.scrbl"]
@include-section["emulab-hardware.scrbl"] @include-section["emulab-hardware.scrbl"]
@include-section["planned.scrbl"] @include-section["planned.scrbl"]
@include-section["openstack-tutorial.scrbl"]
@include-section["getting-help.scrbl"] @include-section["getting-help.scrbl"]
...@@ -39,4 +39,5 @@ The Powder facility is built on top of ...@@ -39,4 +39,5 @@ The Powder facility is built on top of
@include-section["hardware.scrbl"] @include-section["hardware.scrbl"]
@include-section["planned.scrbl"] @include-section["planned.scrbl"]
@include-section["powder-tutorial.scrbl"] @include-section["powder-tutorial.scrbl"]
@include-section["openstack-tutorial.scrbl"]
@include-section["getting-help.scrbl"] @include-section["getting-help.scrbl"]
...@@ -4,21 +4,21 @@ ...@@ -4,21 +4,21 @@
@title{Logging In} @title{Logging In}
The first step is to log in to @(tb); @(tb) is available to all @geniusers-only{
researchers and educators who work in cloud computing. If you have The first step is to log in to @(tb). @clab-only{@(tb) is available to all researchers and educators who work in cloud computing.}
an account at one of its federated facilities, like If you have an account at one of its federated facilities, like
@link["https://www.emulab.net"]{Emulab} or @link["https://www.emulab.net"]{Emulab} or
@link["http://geni.net"]{GENI}, then you already have an account at @link["http://geni.net"]{GENI}, then you already have an account at
@(tb). @(tb).}
@section{Using a @(tb) Account} @geniusers-only{@section{Using a @(tb) Account}}
If you have signed up for an account at the @(tb) website, simply If you have signed up for an account at the @(tb) website, simply
open @url[apt-base-url]in your browser, click the ``Log In'' button, open @url[apt-base-url] in your browser, click the ``Log In'' button,
enter your username and password, and @bold{skip to enter your username and password@geniusers-only{, and @bold{skip to the next part of the tutorial}}.
the next part of the tutorial}.
@screenshot["tutorial/front-page.png"] @geniusers-only{
@clab-screenshot["tutorial/front-page.png"]
@section{Using a GENI Account} @section{Using a GENI Account}
...@@ -28,21 +28,24 @@ features of the @(tb) and GENI portal. ...@@ -28,21 +28,24 @@ features of the @(tb) and GENI portal.
@itemlist[#:style 'ordered @itemlist[#:style 'ordered
@instructionstep["Open the web interface" @instructionstep["Open the web interface"
#:screenshot "tutorial/front-page.png"]{ #:screenshot "tutorial/front-page.png"
#:screenshot-where "clab"]{
To log in to @(tb) using a GENI account, start by visiting To log in to @(tb) using a GENI account, start by visiting
@url[apt-base-url] in your browser and using the ``Log In'' @url[apt-base-url] in your browser and using the ``Log In''
button in the upper right. button in the upper right.
} }
@instructionstep["Click the \"GENI User\" button" @instructionstep["Click the \"GENI User\" button"
#:screenshot "tutorial/login-page.png"]{ #:screenshot "tutorial/login-page.png"
#:screenshot-where "clab"]{
On the login page that appears, you will use the ``GENI User'' button. On the login page that appears, you will use the ``GENI User'' button.
This will start the GENI authorization tool, which lets you connect This will start the GENI authorization tool, which lets you connect
your GENI account with @(tb). your GENI account with @(tb).
} }
@instructionstep["Select the GENI portal" @instructionstep["Select the GENI portal"
#:screenshot "tutorial/authorization-tool.png"]{ #:screenshot "tutorial/authorization-tool.png"
#:screenshot-where "clab"]{
You will be asked which facility your account is with. Select the GENI You will be asked which facility your account is with. Select the GENI
icon, which will take you to the GENI portal. There are several other icon, which will take you to the GENI portal. There are several other
facilities that are federated with @(tb), which can be found in the facilities that are federated with @(tb), which can be found in the
...@@ -50,7 +53,8 @@ features of the @(tb) and GENI portal. ...@@ -50,7 +53,8 @@ features of the @(tb) and GENI portal.
} }
@instructionstep["Log into the GENI portal" @instructionstep["Log into the GENI portal"
#:screenshot "tutorial/geni-login.png"]{ #:screenshot "tutorial/geni-login.png"
#:screenshot-where "clab"]{
You will be taken to the GENI portal, and will need to select the You will be taken to the GENI portal, and will need to select the
institution that is your identity provider. Usually, this is the institution that is your identity provider. Usually, this is the
university you are affiliated with. If your university is not in university you are affiliated with. If your university is not in
...@@ -63,7 +67,8 @@ features of the @(tb) and GENI portal. ...@@ -63,7 +67,8 @@ features of the @(tb) and GENI portal.
} }
@instructionstep["Log into your institution" @instructionstep["Log into your institution"
#:screenshot "tutorial/utah-login.png"]{ #:screenshot "tutorial/utah-login.png"
#:screenshot-where "clab"]{
This will bring you to your institution's standard login page, which you This will bring you to your institution's standard login page, which you
likely use to access many on-campus services. (Yours will look different likely use to access many on-campus services. (Yours will look different
from this one.) from this one.)
...@@ -87,13 +92,14 @@ features of the @(tb) and GENI portal. ...@@ -87,13 +92,14 @@ features of the @(tb) and GENI portal.
this step in the future (you will still be asked to log in to this step in the future (you will still be asked to log in to
the GENI portal). the GENI portal).
@screenshot["tutorial/authorize.png"] @clab-screenshot["tutorial/authorize.png"]
} }
@instructionstep["Set up an SSH keypair in the GENI portal" @instructionstep["Set up an SSH keypair in the GENI portal"
#:screenshot "tutorial/portal-keypair.png"]{ #:screenshot "tutorial/portal-keypair.png"
#:screenshot-where "clab"]{
Though not strictly required, many parts of this tutorial will Though not strictly required, many parts of this tutorial will
work better if you have an @(ssh) public key associated with your GENI work better if you have an @(ssh) public key associated with your GENI
Portal account. To upload one, visit Portal account. To upload one, visit
...@@ -108,5 +114,4 @@ features of the @(tb) and GENI portal. ...@@ -108,5 +114,4 @@ features of the @(tb) and GENI portal.
@margin-note{When you create a new experiment, @(tb) grabs the set of @(ssh) @margin-note{When you create a new experiment, @(tb) grabs the set of @(ssh)
keys you have set up at the time; any @(ssh) keys that you add later are keys you have set up at the time; any @(ssh) keys that you add later are
not added to experiments that are already running.} } ] not added to experiments that are already running.} } ]
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment