A collection of ansible playbooks to build an IPFS cluster setup with TLS termination for the Gateway, UI and HTTP API.
ipfs-cluster.yml: Installs and configures theipfsandipfs-clusterdaemonscertbot.yml: Installs and configures TLS certificates for any number of hostsnginx.yml: Installs and configures nginxnginx-config.yml: Creates the virtual hosts on nginx to expose the HTTP Gateway and the Web UImain.yml: Executes all of the above playbooks in sequence
- Configure the hostnames/addresses for all the nodes in the cluster in
env/ipfs/hosts.yml(replaceipfs-node-xwith your values) - Generate an IPFS Secret and replace the placeholders in
env/ipfs/host_vars/**.ymlas well asenv/ipfs/group_vars/ipts_cluster.ymlwith your values. (Refer to Ansible IPFS Cluster for info on how to get those values) - Add any number of users to the variable
ipfs_cluster_restapi_usersinenv/ipfs/group_vars/ipts_cluster.yml - Replace the value in
env/ipfs/group_vars/all/common.ymlwith your domain name for the TLS certificate. - Create a new file in
env/ipfs/group_vars/alland declare theipfs_nginx_htpasswd,ipfs_nginx_usernameandipfs_nginx_passwordwith values of your choosing. make sure to add that file to gitignore
ansible-playbook -i env/ipfs-cluster main.ymlansible-playbook -i env/ipfs-cluster main.yml --tags nginx