https://github.com/cliffano/knut-haugland
Makefile for creating Kon-Tiki static web sites
https://github.com/cliffano/knut-haugland
kon-tiki makefile website
Last synced: 11 months ago
JSON representation
Makefile for creating Kon-Tiki static web sites
- Host: GitHub
- URL: https://github.com/cliffano/knut-haugland
- Owner: cliffano
- License: cc0-1.0
- Created: 2024-07-10T14:40:36.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2025-01-26T23:10:55.000Z (over 1 year ago)
- Last Synced: 2025-02-12T12:17:51.875Z (over 1 year ago)
- Topics: kon-tiki, makefile, website
- Language: Makefile
- Homepage:
- Size: 755 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README

[](https://github.com/cliffano/knut-haugland/actions/workflows/ci-workflow.yaml)
Knut Haugland
-------------
Knut Haugland is a Makefile for creating Kon-Tiki static web sites.
It provides utility targets for building, deploying, and managing the infrastructure of the static web sites.
Have a look at [examples/](examples/) for example projects of how Knut Haugland can be used.


Installation
------------
1. Download `src/Makefile-knut-haugland` as the `Makefile` of your project:
`curl https://raw.githubusercontent.com/cliffano/knut-haugland/main/src/Makefile-knut-haugland -o Makefile`
2. Create configuration file `knut-haugland.yml` with properties described in [Configuration](#configuration) section
3. Run the available `Makefile` targets described in [Usage](#usage) section
Configuration
-------------
Create KnutHaugland configuration file called `knut-haugland.yml` with contains the following properties:
| Property | Description | Example |
|----------|-------------|---------|
| aws_region | [AWS region code](https://www.aws-services.info/regions.html) | `ap-southeast-2` |
| bucket_name | [S3 bucket name for the static web site](https://docs.aws.amazon.com/AmazonS3/latest/userguide/WebsiteHosting.html) | `knuthauglandexample.example.com` |
Usage
-----
The following targets are available:
| Target | Description |
|--------|-------------|
| ci | CI target to be executed by CI/CD tool, end to end build of the static web site |
| stage | Ensure stage directory exists |
| clean | Remove all temporary (staged, generated, cached) files |
| deps | Retrieve package dependencies using [Bob](https://github.com/cliffano/bob/) |
| update-to-latest | Update Makefile to the latest version on origin's main branch |
| update-to-version | Update Makefile to the version defined in `TARGET_KNUT_HAUGLAND_VERSION` parameter |
| build | Build the static web site using [AE86](https://github.com/cliffano/ae86/) |
| deploy | Sends the built static web site code to AWS S3 bucket |
| publish | A convenient target for running: clean deps init build deploy |
| infra- | Targets for managing the infrastructure built using [Terraform AWS Kon-Tiki](https://github.com/cliffano/terraform-aws-kon-tiki/) |
Colophon
--------
Related Projects:
* [generator-kon-tiki](https://github.com/cliffano/generator-kon-tiki) - Kon-Tiki static web site projects generator using Plop