Skip to main content

signaloid-cli auth login

Authenticate with Signaloid Cloud Compute Engine.

Synopsis

signaloid-cli auth login [--api-key <key>] [--email <email>] [--password <password>]

Options

OptionDescription
--api-key <key>Signaloid API key for authentication
--email <email>Email address for password-based authentication
--password <password>Password for authentication

Examples

signaloid-cli auth login --api-key scce_1234567890abcdef

Email/Password Login

signaloid-cli auth login --email user@example.com --password mypassword

Using Environment Variable

export SIGNALOID_API_KEY=scce_1234567890abcdef
signaloid-cli auth login --api-key $SIGNALOID_API_KEY

CI/CD Integration

GitHub Actions:

- name: Authenticate with Signaloid
env:
SIGNALOID_API_KEY: ${{ secrets.SIGNALOID_API_KEY }}
run: |
signaloid-cli auth login --api-key $SIGNALOID_API_KEY
signaloid-cli auth whoami

GitLab CI:

before_script:
- signaloid-cli auth login --api-key $SIGNALOID_API_KEY
- signaloid-cli auth whoami

Script with Error Handling

#!/bin/bash

API_KEY="${SIGNALOID_API_KEY}"

if [ -z "$API_KEY" ]; then
echo "Error: SIGNALOID_API_KEY not set"
exit 1
fi

# Authenticate
if signaloid-cli auth login --api-key "$API_KEY"; then
echo "✓ Authentication successful"
else
echo "✗ Authentication failed"
exit 1
fi

# Verify
if signaloid-cli auth whoami > /dev/null 2>&1; then
echo "✓ Credentials valid"
EMAIL=$(signaloid-cli auth whoami | jq -r '.email')
echo "Logged in as: $EMAIL"
else
echo "✗ Invalid credentials"
exit 1
fi

Notes

  • API key authentication is recommended for automation and CI/CD
  • Credentials are stored securely in your config directory
  • On Unix systems, config files are created with restricted permissions (0600)
  • Email validation is performed before attempting authentication
  • Empty passwords and API keys are rejected

Authentication Modes

API Key Authentication

API keys provide programmatic access without requiring password entry:

Advantages:

  • No password prompts in scripts
  • Easy to rotate and revoke
  • Ideal for CI/CD pipelines
  • Can have different keys for different environments

Create an API key:

  1. Visit signaloid.io/settings/api
  2. Generate a new API key
  3. Store it securely in environment variables or secrets manager

Email/Password Authentication

Interactive authentication using your Signaloid account credentials:

Security note: Avoid hardcoding passwords in scripts. Use API keys instead for automation.

Exit Codes

CodeDescription
0Authentication successful
1Authentication failed or invalid credentials

Troubleshooting

"Authentication failed" Error

Problem: Login fails with authentication error.

Solutions:

  1. Verify your API key is correct
  2. Check for extra spaces or newlines in the key
  3. Generate a new API key from signaloid.io/settings/api
  4. Verify network connectivity

"Invalid email address" Error

Problem: Email validation fails during login.

Solutions:

  1. Ensure email is in correct format: user@example.com
  2. Check for typos
  3. Don't include spaces before or after email

"API key cannot be empty" Error

Problem: Attempting to login with empty API key.

Solutions:

  1. Verify environment variable is set: echo $SIGNALOID_API_KEY
  2. Check for quote issues in shell
  3. Ensure API key is passed correctly

See Also

Learn More