darkwizard242.hugo
Ansible Role: Hugo
This role installs the extended version of Hugo by default on Debian/Ubuntu and EL systems.
Requirements
No additional requirements.
Role Variables
Here are the available variables (found in defaults/main.yml
):
Variables list:
hugo_app: hugo_extended
hugo_version: 0.133.1
hugo_os: "{{ ansible_system | lower }}"
hugo_architecture_map:
amd64: amd64
arm: arm64
x86_64: amd64
armv6l: armv6
armv7l: armv7
aarch64: arm64
32-bit: "386"
64-bit: amd64
hugo_dl_url: https://github.com/gohugoio/hugo/releases/download/v{{ hugo_version }}/{{ hugo_app }}_{{ hugo_version }}_{{ hugo_os }}-{{ hugo_architecture_map[ansible_architecture] }}.tar.gz
hugo_bin_path: /usr/local/bin
hugo_file_owner: root
hugo_file_group: root
hugo_file_mode: '0755'
Variables table:
Variable | Description |
---|---|
hugo_app | Specifies the app to install, i.e., hugo_extended |
hugo_version | Set to fetch the desired version to install dynamically. Defaults to: 0.133.1 |
hugo_os | Defines the operating system type. Used for getting the correct binaries based on OS. |
hugo_architecture_map | Defines the architecture type. Used for getting the correct binaries based on architecture. |
hugo_dl_url | URL to download the Hugo binary. |
hugo_bin_path | Defines the path to store the Hugo binary. Defaults to: /usr/local/bin (common user PATH). |
hugo_file_owner | Owner of the Hugo binary file. |
hugo_file_group | Group for the Hugo binary file. |
hugo_file_mode | Permissions for the Hugo binary file. |
Dependencies
No dependencies required.
Example Playbook
To use the role for the default installation of Hugo in Ansible playbooks:
- hosts: servers
roles:
- darkwizard242.hugo
To customize the role (e.g., specify the Hugo version) in Ansible playbooks:
- hosts: servers
roles:
- darkwizard242.hugo
vars:
hugo_version: 0.78.2
To customize the role (e.g., change the location of the Hugo binary) in Ansible playbooks:
- hosts: servers
roles:
- darkwizard242.hugo
vars:
hugo_bin_path: /bin/
License
Author Information
This role was created by Ali Muhammad.
Informazioni sul progetto
Installs/Uninstalls 'Hugo', which is one of the most popular open source static site generator.
Installa
ansible-galaxy install darkwizard242.hugo
Licenza
mit
Download
4.5k
Proprietario
Senior DevOps/CloudOps Engineer.
Dedicated to Automating everything I come across.
Love to work on and learn new technologies/tools everyday!