This is the source code for mikebroadway.com, a photography web site generated by Hugo. The site is entirely static, i.e. with no dedicated web server but instead hosted entirely by Amazon S3 storage.
The site layout is derived from the Newsroom Hugo Theme, designed and developed by wero and referenced as a gitmodule; see .gitmodules.
Image gallery display, with fullscreen and slide show capabilities, is handled by lightgallery.js. While this is available as open source code under a GPLv3 license it is well worth the small fee charged for a commercial license, even for personal projects like this one.
Being a responsive web site design for displaying photographs, mikebroadway.com
contains hundreds of megabytes of image files. Being too bulky, the photographs themselves are not
contained in this source code repository; .gitignore
excludes the /static/images
directory.
See the LICENSE file for the license rights and limitations covering different aspects of this respository's contents.
IMPORTANT: The lightgallery.js source code used by this project is separately licensed; it is NOT covered by the MIT license that applies to the source code in this repository. lightgallery.js is available as open source code under a GPLv3 license that is incompatible with the MIT license referenced above.
If you wish to utilize the lightgallery.js, lg-autoplay.js, lg-fullscreen.js, or lightgallery.css files in your own web site, you must either open source your code under a GPLv3 license or purchase a commercial license for lightgallery.js. At the time of writing, this is an affordable $18 (U.S) for an unlimited number of personal projects.
Hugo allows multiple configuration files to be combined at build and/or run time. When building
mikebroadway.com, a second private.toml
configuration is specificied
in addition to the default config.toml
; private.toml
is used to define the
Google Analytics ID that is specific to mikebroadway.com so that
anyone that simply clones this repository to experiment with will not accidentally add to the
analytics data collected for the actual mikebroadway.com site.
As with any normal Hugo project, the site can be run locally at http://localhost:1313/ using the folowing command in the project root:
hugo server -D --config config.toml,private.toml
The -D
switch will include any draft pages.
If you don't need to add to any of the configuration in the config.toml
file, i.e. you don't have any
configuration values that you do not wnat to have cloned from a public git repository, you can omit
the --config config.toml,private.toml
switch and allow config.toml
to be used by default.
The site must first be built into the /public
directory with the undecorated hugo
command:
hugo --config config.toml,private.toml
Then the contents of the /public
directory myst be synced to the target S3 bucket:
. ./sync.sh
Naturally, you will need to modify the sync.sh script to reference your own S3 bucket location! And you must have established appropriate access keys for the aws s3 sync
command to work!
See Hosting a Static Website on Amazon S3 and Example: Setting Up a Static Website Using a Custom Domain.