-
Notifications
You must be signed in to change notification settings - Fork 1
Remote Hosting
Below are examples of how b-ber projects can be hosted remotely. This not meant to be an exhaustive list, but rather to demonstrate a few different approaches that can be taken to publish b-ber projects online.
-
Update the config.yml file to point at the your domain, which will be passed in later. Note that the filenames for the EPUB and Mobi builds will be the value of the
identifier
field in metadata.yml
# config.yml
base_path: /
reader_url: https://example.com
remote_url: https://example.com
downloads:
- label: Download as Epub
title: b-ber All Directives Demo
url: >-
https://example.com/a16c595e6b08d4d86bf3854b982cd8d6acf74c5a.epub
- label: Download as Mobi
title: b-ber All Directives Demo
url: >-
https://example.com/a16c595e6b08d4d86bf3854b982cd8d6acf74c5a.mobi
- Build a Reader version of the project and any other output formats that you'd like to make available to download.
$ bber build reader epub mobi
-
Open your FTP manager and login to your remote host.
-
Navigate to your public folder, which is typically named public_html.
-
Upload the contents of the project-reader directory to the public folder.
-
Upload the builds that you would like to make available for download into the same folder.
Surge.sh offers free hosting and the ability to upload files on the command line.
- Install the Surge CLI tool
$ npm i --global surge
- Update the config.yml file to point at the Surge domain which will be passed in later. Note that the filenames for the EPUB and Mobi builds will be the value of the
identifier
field in metadata.yml
# config.yml
base_path: /
reader_url: http://b-ber-all-directives-demo.surge.sh
remote_url: http://b-ber-all-directives-demo.surge.sh
downloads:
- label: Download as Epub
title: b-ber All Directives Demo
url: >-
http://b-ber-all-directives-demo.surge.sh/a16c595e6b08d4d86bf3854b982cd8d6acf74c5a.epub
- label: Download as Mobi
title: b-ber All Directives Demo
url: >-
http://b-ber-all-directives-demo.surge.sh/a16c595e6b08d4d86bf3854b982cd8d6acf74c5a.mobi
- Build a Reader version of the project and any other output formats that you'd like to make available to download.
$ bber build reader epub mobi
- Copy the assets that you would like to make downloadable to the project-reader directory.
$ cp *.epub *.mobi ./project-reader
- Deploy the project using the Surge CLI tool, passing in the desired domain.
$ surge --domain b-ber-all-directives-demo.surge.sh ./project-reader
A demo of a b-ber project deployed to Surge, can found here.
- Adding metadata
- Creating content
- Generating new content
- Authoring and editing content
- Reading order (Table of Contents)
- Configuring the build
- Adding a cover image
- All directives
- Text
- Media
- Misc