Bug 1267765

Summary: Unable to add articles to manually created website in Publican 3.2
Product: [Community] Publican Reporter: Cheryl Fernandes <cheryl.fernandes>
Component: publicanAssignee: Ruediger Landmann <rlandman>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: unspecified    
Version: 3.2CC: cbredesen, jfearn, lepata2002, me, mmcallis, rlandman
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Other   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-01-09 11:44:52 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Cheryl Fernandes 2015-09-30 22:47:26 UTC
Description of problem:
I'm using CentOS7 and have Publican3.2 installed. I'm trying to build a website manually but am having trouble integrating Articles into the website.

I was able to create to site structure using: <publican create_site>

I'm able to create Articles inside the website folder using <publican create --type Article --name page_name> and build them using <publican build --publish --formats html-single --embedtoc --langs all > but how do I add them to my webpage?
I have tried using <publican update_site> but that doesnt work. 

Version-Release number of selected component (if applicable):
Publican3.2 

How reproducible:
Easy


Steps to Reproduce:
1. Create a folder 'test'
2. cd into the folder and create a the website structure using publican create_site
3. In this folder, create an article using publican create --type Article --name page_name
4. Build the article using publican build --publish --formats html-single --embedtoc --langs all 
5. cd to the website folder and run publican update_site --site_config path_to_site_configuration_file.cfg
6. Go to html/docs/en-US/ folder and open up, index.html

Actual results:
The page has the word 'Products' and a search bar.

Expected results:
I'm expecting the article and the TOC to show up like when I create a document.


Additional info:
None.

Comment 1 Jeff Fearn 🐞 2015-10-06 22:25:32 UTC
Looks like you aren't installing the book.

4.1. Install the book: publican install_book --site_config path_to_site_configuration_file.cfg --lang en-US

Unfortunately this action only takes one language at a time so you need to do it in a loop.

Comment 2 Cheryl Fernandes 2015-10-16 22:37:56 UTC
I tried the following:
1. cd into the article folder e.g. Home_Page
2. build the article
publican build --publish --formats html-single --embedtoc 
3. Add the article into the website. Run this command from the article folder i.e. same location where the previous command is run
publican install_book --site_config <path to my sites>

Actual results:
The page has the word 'Products' and a search bar.

Expected results:
I'm expecting the article and the TOC to show up like when I create a document.

In other words, these commands haven't made a difference. If it helps, I'm using Publican version 3.2. Please advise.

Comment 3 Cheryl Fernandes 2015-10-17 00:06:19 UTC
Additionally, whenever I try to build using parameter 'embedtoc', for some reason all the styling goes away and I'm left with just the basic HTML being displayed. I have seen someone report this bug earlier but was it fixed for V3.2 and greater?
Thanks for all your help.

Comment 4 Jeff Fearn 🐞 2015-10-18 22:44:03 UTC
Hi Cheryl, it looks to me like you are trying to add an article before you add a home page, or you haven;t got your home page configured properly.

The order of installing and configuring is critical.

https://jfearn.fedorapeople.org/en-US/Publican/4.3/html/Users_Guide/chap-Publican-Users_Guide-Building_a_website_with_Publican.html#sect-Publican-Users_Guide-Building_a_website_with_Publican-Building_a_website_manually

I point to the latest version of the doc not because the process has changed much, but because the docs have been improved and are more accurate as to order and configuration.

Comment 5 Cheryl Fernandes 2015-10-19 21:38:56 UTC
1. I followed the instructions as per V4.3 of publican. Turns out that the instructions were right and I followed them right. What was giving me trouble was the "host" property of my sites .cfg file 

When I would declare it like, "host: localhost", the links to the js and css files in var/www/html/docs/en-US/index.html would be, "http://localhost/docs/en-US/localhost/docs/toc.js" which results in a 404 error and that why I was only seeing the product text with the search bar. 

After I changed the hostname in the .cfg to, "host: ../../docs/", the links to the css and js file were, "http://localhost/docs/en-US/toc.js" which is why I can now see the menu and the content. Not sure if this is correct but this is how I got it to work.

I am now facing issues with the table of contents namely the iframe with 
body of class="tocnav". 
I see the logo, the search bar and the Language dropdown with the 'collapse all' link but how do I add the article I just created namely, FooMaster and FooMaster_3 with web_type: product/version respectively to the navigation menu?
Thanks for all your help so far.

Comment 6 Elena Mishina 2016-02-05 09:36:26 UTC
Description of problem:
I'm using AltLinux and have Publican3.0 installed. I'm trying to build a website manually but am having trouble integrating Articles into the website.

Home page installed.

Steps to Reproduce:
1. Create an article using publican create --type Article --name page_name
2. cd to the page_name folder
3. Build the article using publican build --publish --formats html-single --embedtoc --langs all
4. Install the book: publican install_book --site_config path_to_site_configuration_file.cfg --lang en-US
5. Go to html/docs/en-US/ folder and open up, index.html

Version-Release number of selected component (if applicable):
Publican3.0

Actual results:
The page has the word 'Products', a search bar, select language, home page.
File .db does not change.

Expected results:
I'm expecting the article and menu in the TOC to show up like when I create a document.
Insert in .db


Additional info:
None.

Comment 7 Jeff Fearn 🐞 2016-02-07 23:56:30 UTC
(In reply to Cheryl Fernandes from comment #5)
> 1. I followed the instructions as per V4.3 of publican. Turns out that the
> instructions were right and I followed them right. What was giving me
> trouble was the "host" property of my sites .cfg file 
> 
> When I would declare it like, "host: localhost", the links to the js and css
> files in var/www/html/docs/en-US/index.html would be,
> "http://localhost/docs/en-US/localhost/docs/toc.js" which results in a 404
> error and that why I was only seeing the product text with the search bar. 
> 
> After I changed the hostname in the .cfg to, "host: ../../docs/", the links
> to the css and js file were, "http://localhost/docs/en-US/toc.js" which is
> why I can now see the menu and the content. Not sure if this is correct but
> this is how I got it to work.
> 
> I am now facing issues with the table of contents namely the iframe with 
> body of class="tocnav". 
> I see the logo, the search bar and the Language dropdown with the 'collapse
> all' link but how do I add the article I just created namely, FooMaster and
> FooMaster_3 with web_type: product/version respectively to the navigation
> menu?
> Thanks for all your help so far.

Hi Cheryl, I think it's the relative path in site, can you try setting "host: /docs/"

Comment 8 Jeff Fearn 🐞 2016-02-07 23:57:27 UTC
(In reply to Elena Mishina from comment #6)
> Description of problem:
> I'm using AltLinux and have Publican3.0 installed. I'm trying to build a
> website manually but am having trouble integrating Articles into the website.
> 
> Home page installed.
> 
> Steps to Reproduce:
> 1. Create an article using publican create --type Article --name page_name
> 2. cd to the page_name folder
> 3. Build the article using publican build --publish --formats html-single
> --embedtoc --langs all
> 4. Install the book: publican install_book --site_config
> path_to_site_configuration_file.cfg --lang en-US
> 5. Go to html/docs/en-US/ folder and open up, index.html
> 
> Version-Release number of selected component (if applicable):
> Publican3.0
> 
> Actual results:
> The page has the word 'Products', a search bar, select language, home page.
> File .db does not change.
> 
> Expected results:
> I'm expecting the article and menu in the TOC to show up like when I create
> a document.
> Insert in .db
> 
> 
> Additional info:
> None.

Hi Elenea, you probably need to run the install as root.

Comment 9 Jeff Fearn 🐞 2017-01-09 11:44:52 UTC
No response.