openfaas / faasd

A lightweight & portable faas engine
https://store.openfaas.com/l/serverless-for-everyone-else
MIT License
2.98k stars 214 forks source link

set HOME variable when not available, e.g when running with cloud-init #283

Closed jsiebens closed 2 years ago

jsiebens commented 2 years ago

Description

Apparently, HOME variable isn't always set when cloud-init executes a startup script, causing the install.sh script to fail. This PR adds an additional check to see if this is the case and sets the variable if required.

Motivation and Context

How Has This Been Tested?

Launched multiple VMs, locally with lima or mulitpass and on different cloud providers (GPC and AWS using Terraform) with this updated install script.

Types of changes

Checklist:

Commits:

Code:

Docs:

alexellis commented 2 years ago

Thanks for this PR.