Browse Source

HUE-8741 [doc] Add correct link for the images

Romain Rigaux 6 years ago
parent
commit
ce18113785

+ 8 - 6
docs/docs-site/config.toml

@@ -1,4 +1,4 @@
-baseURL='http://cloudera.github.io/hue/docs-4.4.0/'
+baseURL = 'http://cloudera.github.io/hue/docs-4.4.0/' # Note: also in params
 
 languageCode = "en-us"
 title = "Hue Documentation"
@@ -11,9 +11,11 @@ theme = "hugo-theme-learn"
 home = [ "HTML", "RSS", "JSON"]
 
 [params]
-  # Prefix URL to edit current page. Will display an "Edit this page" button on top right hand corner of every page. 
+  # For logo and favicon partials
+  baseURL = 'http://cloudera.github.io/hue/docs-4.4.0/'
+
+  # Prefix URL to edit current page. Will display an "Edit this page" button on top right hand corner of every page.
   # Useful to give opportunity to people to create merge request for your doc.
-  # See the config.toml file from this documentation site to have an example.
   editURL = "https://github.com/cloudera/hue/blob/master/docs/docs-site/content/"
   # Author of the site, will be used in meta information
   author = ""
@@ -23,12 +25,12 @@ home = [ "HTML", "RSS", "JSON"]
   showVisitedLinks = false
   # Disable search function. It will hide search bar
   disableSearch = false
-  # Javascript and CSS cache are automatically busted when new version of site is generated. 
+  # Javascript and CSS cache are automatically busted when new version of site is generated.
   # Set this to true to disable this behavior (some proxies don't handle well this optimization)
   disableAssetsBusting = false
   # Set this to true to disable copy-to-clipboard button for inline code.
   disableInlineCopyToClipBoard = false
-  # A title for shortcuts in menu is set by default. Set this to true to disable it. 
+  # A title for shortcuts in menu is set by default. Set this to true to disable it.
   disableShortcutsTitle = false
   # When using mulitlingual website, disable the switch language button.
   disableLanguageSwitchingButton = false
@@ -41,7 +43,7 @@ home = [ "HTML", "RSS", "JSON"]
   # Change default color scheme with a variant one. Can be "red", "blue", "green".
   themeVariant = "hue"
 
-[[menu.shortcuts]] 
+[[menu.shortcuts]]
 name = "<i class='fab fa-github'></i> Github"
 identifier = "ds"
 url = "https://github.com/cloudera/hue"

+ 4 - 4
docs/docs-site/content/developer/application/_index.md

@@ -29,7 +29,7 @@ and will walk you through adding a new application using the SDK.
 
 ### From 30,000 feet
 
-![From up on high](/images/from30kfeet.png)
+![From up on high]({{% param baseURL %}}images/from30kfeet.png)
 
 Hue, as a "container" web application, sits in between your Hadoop installation
 and the browser.  It hosts all the Hue Apps, including the built-in ones, and
@@ -37,7 +37,7 @@ ones that you may write yourself.
 
 ### The Hue Server
 
-![Web Back-end](/images/webbackend.png)
+![Web Back-end]({{% param baseURL %}}images/webbackend.png)
 
 Hue is a web application built on the Django python web framework.
 Django, running on the WSGI container/web server (typically CherryPy), manages
@@ -52,7 +52,7 @@ daemon processes "on the side". Some examples are the `Celery Task Server`, `Cel
 
 ### Interacting with Hadoop
 
-![Interacting with Hadoop](/images/interactingwithhadoop.png)
+![Interacting with Hadoop]({{% param baseURL %}}images/interactingwithhadoop.png)
 
 Hue provides some APIs for interacting with Hadoop.
 Most noticeably, there are python file-object-like APIs for
@@ -69,7 +69,7 @@ Hue provides a front-end framework based on
 
 ### An Architectural View
 
-![Architecture](/images/architecture.png)
+![Architecture]({{% param baseURL %}}images/architecture.png)
 
 A Hue application may span three tiers: (1) the UI
 and user interaction in the client's browser, (2) the

+ 6 - 6
docs/docs-site/content/user/browsers/_index.md

@@ -210,13 +210,13 @@ must have the proper permissions to manipulate other user's files.
 
 -   Click the directory name or parent directory dots in the **File
     Browser** window.
--   Click the ![image](images/edit.png) icon, type a directory name, and
+-   Click the Edit icon, type a directory name, and
     press **Enter**.
 
 To change to your home directory, click **Home** in the path field at
 the top of the **File Browser** window.
 
-![image](images/note.jpg) **Note**:
+**Note**:
 
 The **Home** button is disabled if you do not have a home directory. Ask
 a Hue administrator to create a home directory for you.
@@ -265,12 +265,12 @@ in the folder have the full path of the deleted files (in order to be
 able to restore them if needed) and checkpoints. The length of time a
 file or directory stays in the trash depends on HDFS properties.
 
-In the **File Browser** window, click ![image](images/fbtrash.png).
+In the **File Browser** window, click the Trash icon.
 
 
 ### Changing Owner, Group, or Permissions
 
-![image](images/note.jpg) **Note**:
+**Note**:
 
 Only the Hadoop superuser can change a file's or directory's owner,
 group, or permissions. The user who starts Hadoop is the Hadoop
@@ -375,8 +375,8 @@ If there are jobs running, then the Job Browser list appears.
 
 ### Viewing Job Information
 
-![image](images/note.jpg) **Note**: At any level you can view the log
-for an object by clicking the ![image](images/log.png) icon in the Logs
+**Note**: At any level you can view the log
+for an object by clicking the Log icon in the Logs
 column.
 
 **To view job information for an individual job:**

+ 2 - 1
docs/docs-site/content/user/concept/_index.md

@@ -31,7 +31,8 @@ Each app of Hue can be extended to support your own languages or apps as detaile
 
 The layout simplifies the interface and is now single page app, and this makes things snappier and unifies the apps together.
 
-![image](/images/hue-4-interface-concept.png)
+
+![image]({{% param baseURL %}}images/hue-4-interface-concept.png)
 
 From top to bottom we have:
 

+ 1 - 1
docs/docs-site/content/user/contrib/_index.md

@@ -24,7 +24,7 @@ Prerequisites before using the app:
 to point to your Thrift IP/Port
 
 
-![image](images/note.jpg) **Note**: With just a few changes in the [Python API](https://github.com/cloudera/hue/blob/master/apps/hbase/src/hbase/api.py),
+**Note**: With just a few changes in the [Python API](https://github.com/cloudera/hue/blob/master/apps/hbase/src/hbase/api.py),
 the HBase browser could be compatible with Apache Kudu.
 
 

+ 7 - 8
docs/docs-site/content/user/editor/_index.md

@@ -36,7 +36,7 @@ Secondly, we need to add a new interpreter to the notebook app. This will allow
 ## Concepts
 ### Running Queries
 
-![image](images/note.jpg) **Note**: To run a query, you must be logged
+**Note**: To run a query, you must be logged
 in to Hue as a user that also has a Unix user account on the remote
 server.
 
@@ -59,20 +59,20 @@ server.
 
 When you have multiple statements it's enough to put the cursor in the statement you want to execute, the active statement is indicated with a blue gutter marking.
 
-![image](images/note.jpg) **Note**: Use CTRL/Cmd + ENTER to execute queries.
+**Note**: Use CTRL/Cmd + ENTER to execute queries.
 
-![image](images/note.jpg) **Note**: Under the logs panel, you can view any
+**Note**: Under the logs panel, you can view any
 MapReduce or [Impala jobs](#impala-queries) that the query generated.
 
 ### Downloading and Exporting Query Results
 
 To get things started, press the export icon, the bottom last element of the action bar to the top left of the results. There are several ways you can export results of a query.
 
-![image](images/note.jpg) Two of them offer great scalability:
+Two of them offer great scalability:
 1.  Export to an empty folder on your cluster's file system. This exports the results using multiple files. In the export icon, choose Export and then All.
 2.  Export to a table. You can choose an already existing table or a new one. In the export icon, choose Export and then Table.
 
-![image](images/note.jpg) Two of them offer limited scalability:
+Two of them offer limited scalability:
 1.  Export to a file on your cluster's file systems. This exports the results to a single file. In the export icon, choose Export and then First XXX.
 2.  Download to your computer as a CSV or XLS. This exports the results to a single file in comma-separated values or Microsoft Office Excel format. In the export icon, choose Download as CSV or Download as XLS.
 
@@ -119,11 +119,10 @@ added files to all machines in the cluster at query execution time.
         cache. Typically, this might be a transform script (or similar)
         to be executed.
 
-<li>   For Path, enter the path to the file or click
-    ![image](images/browse.png) to browse and select the file.
+<li>   For Path, enter the path to the file or click browse and select the file.
 </ol>
 
-![image](images/note.jpg) Note: It is not necessary to specify files
+Note: It is not necessary to specify files
 used in a transform script if the files are available in the same path
 on all machines in the Hadoop cluster.</td></tr>
 <tr><td>USER-DEFINED FUNCTIONS</td><td>Specify user-defined functions. Click Add to configure a new

+ 8 - 8
docs/docs-site/content/user/scheduler/_index.md

@@ -42,21 +42,21 @@ actions themselves and the areas above and below the actions. If you
 drop an action on an existing action, a fork and join is added to the
 workflow.
 
--   Add actions to the workflow by clicking an action
-    ![image](images/action.png) button and drop the action on the
+-   Add actions to the workflow by clicking the action
+    button and drop the action on the
     workflow. The Edit Node screen displays.
     1.  Set the action properties and click **Done**. Each action in a
         workflow must have a unique name.
 
--   Copy an action by clicking the ![image](images/copy.png) **Copy**
+-   Copy an action by clicking the **Copy**
     button.
 
 1.  The action is opened in the Edit Node screen.
 2.  Edit the action properties and click **Done**. The action is added
     to the end of the workflow.
 
--   Delete an action by clicking the ![image](images/trash.png) button.
--   Edit an action by clicking the ![image](images/edit.png) button.
+-   Delete an action by clicking the Trash button.
+-   Edit an action by clicking the Edit button.
 -   Change the position of an action by left-clicking and dragging an
     action to a new location.
 
@@ -67,14 +67,14 @@ workflow.
 -   Remove a fork and join by dragging a forked action and dropping it
     above the fork.
 -   Convert a fork to a decision by clicking the
-    ![image](images/convert.png) button.
+    Fork button.
 -   To edit a decision:
-    1.  Click the ![image](images/edit.png) button.
+    1.  Click the Edit button.
     2.  Fill in the predicates that determine which action to perform
         and select the default action from the drop-down list.
     3.  Click **Done**.
 
-![image](images/note.jpg) **Note**: worfklows.xml and their job.properties
+**Note**: worfklows.xml and their job.properties
 cab also directly be selected and executed via the File Browser.
 
 ## Schedules

+ 1 - 2
docs/docs-site/layouts/partials/favicon.html

@@ -1,2 +1 @@
-<link rel="shortcut icon" href="/hue/images/favicon.ico" type="image/x-icon" />
-
+<link rel="shortcut icon" href="{{ .Site.Params.baseURL }}images/favicon.ico" type="image/x-icon" />

+ 1 - 1
docs/docs-site/layouts/partials/logo.html

@@ -1 +1 @@
-<img src="/hue/images/hue_logo.png" alt="alt text" title="Hue Logo">
+<img src="{{ .Site.Params.baseURL }}/images/hue_logo.png" alt="alt text" title="Hue Logo">