Setting Up AliasVault Development Environment on Linux/MacOS
This guide will help you set up AliasVault for development on Linux or MacOS systems.
Prerequisites
- Install .NET 9 SDK
# On MacOS via brew: brew install --cask dotnet-sdk # On Linux: # Follow instructions at https://dotnet.microsoft.com/download/dotnet/9.0
- Install Docker
- Follow instructions at Docker Desktop
- For Linux, you can also use the native Docker daemon
Setup Steps
- Clone the Repository
git clone https://github.com/lanedirt/AliasVault.git cd AliasVault
- Install dotnet CLI EF Tools
# Install dotnet EF tools globally dotnet tool install --global dotnet-ef # Add to your shell's PATH (if not already done) # For bash/zsh, add to ~/.bashrc or ~/.zshrc: export PATH="$PATH:$HOME/.dotnet/tools" # Verify installation dotnet ef
- Install dev database
./install.sh configure-dev-db
- Run Tailwind CSS compiler
# For Admin project cd src/AliasVault.Admin npm run build:admin-css # For Client project cd src/AliasVault.Client npm run build:client-css
- Install Playwright for E2E tests
# Install Playwright CLI dotnet tool install --global Microsoft.Playwright.CLI # Install browsers pwsh src/Tests/AliasVault.E2ETests/bin/Debug/net9.0/playwright.ps1 install
- Configure Development Settings Create
wwwroot/appsettings.Development.json
in the Client project:{ "ApiUrl": "http://localhost:5092", "PrivateEmailDomains": ["example.tld"], "SupportEmail": "support@example.tld", "UseDebugEncryptionKey": "true", "CryptographyOverrideType": "Argon2Id", "CryptographyOverrideSettings": "{\"DegreeOfParallelism\":1,\"MemorySize\":1024,\"Iterations\":1}" }
Running the Application
- Start the Development Database
./install.sh configure-dev-db
- Run the Application
# Using dotnet CLI cd src/AliasVault.Api dotnet run # Or using your preferred IDE (VS Code, Rider, etc.)
Troubleshooting
Database Issues
If you encounter database connection issues:
- Check Database Status
docker ps | grep postgres-dev
- Check Logs
docker logs aliasvault-dev-postgres-dev-1
- Restart Database
./install.sh configure-dev-db
Common Issues
- Permission Issues
# Fix script permissions chmod +x install.sh
- Port Conflicts
- Check if port 5433 is available for the development database
- Check if port 5092 is available for the API
Additional Notes
- Keep your .NET SDK and Docker up to date
- The development database runs on port 5433 to avoid conflicts
- Use the debug encryption key in development for easier testing
- Store sensitive data in environment variables or user secrets
Support
If you encounter any issues not covered in this guide, please:
- Check the GitHub Issues
- Search for existing solutions
- Create a new issue if needed