Automated setups for devops and data science
1 Introduction to YAML Scripts
This is a Quarto document that describes the YAML scripts that you can find in the subdirectory scripts of this repo. There is a chapter for each script, and the chapter contains a description of the script, its purpose, and how to use it.
1.1 Cloud-config scripts
The scripts in this repository are written in YAML format and can be used as user data when launching cloud instances on various cloud providers, such as Hetzner or DigitalOcean. The contents of the user data field are passed to the instance as a file, which is then processed by the cloud-init service. This allows you to automate the setup of your instance, such as installing software, configuring services, and running scripts. Cloud init is the standard for customising cloud instances.
1.2 Requirements
Check these things manually first: - Make sure the R apt source matches the system (see https://cran.rstudio.com/bin/linux/ubuntu/fullREADME.html for names) - If running on smaller droplet uncomment the section that enlarges swapfile - Optional: add SSH public key for user account
1.3 Scripts
You can find the scripts in the scripts directory, or click here:
analysis.yaml: Installs R (with the hadleyverse and close friends) + Python 3 + numpy + pandas + Dockeropenvpn.yaml: Installs and configures an OpenVPN server and generates a ready-to-use client certificateshiny-server.yaml: Installs R + Nginx + Shinypptx2md.yaml: Installs pptx2md
1.4 Documentation
You can find the explanations of the scripts in the documentation that is created with the help of Quarto and GitHub Pages. See the link in the About section of this repository for the documentation site.
1.5 Sources
The original code was adapted from various sources, including the scripts in this respository by Andrew Heiss and this tutorial by the Digital Ocean community. Also, I benefited from the results of penetration tests that have been performed for acquiring ISO and NEN certifications for my consulting firm Equalis.