Sitecore Commerce InitializeEnvironment error: 'Failed to get connection for Sitecore'

After installing Sitecore Commerce 8.2.1 using the provided powershell scripts, the initialize environment command failed with the following error: localhost:5000/commerceops/InitializeEnvironment(environment='HabitatAuthoring') { "@odata.context":"http://localhost:5000/CommerceOps/$metadata#Commands/$entity", "@odata.type":"#Sitecore.Commerce.Core.Commands.InitializeEnvironmentCommand&…