Deployment Strategies
Best for: Basic applications with minimal complexity, such as simple prompting agentsIn this approach, you use a single workspace for both development and production:
- Development: Create and test your application directly in the workspace
- Production: Once tested, the same workspace serves as the production environment
- Version Control: Use versioning to save stable points for potential rollback
- Simplest deployment approach
- No need to migrate between workspaces
- Quick iteration and updates
- Limited separation between development and production
- Higher risk of disruptive changes affecting live users
- Best suited for applications with low complexity and minimal regulatory constraints
Versioning Your Application
1
Configure Git Repository
Set up version control for your workspace:
- Access workspace raw configuration by clicking “Edit source code” in the workspace action menu
- Add repository configuration to the end of the file:
You can use secrets for sensitive information:
For SSH authentication, use:Remember to use
git@github.com:YourUser/your-repository.git
format for SSH URLs.2
Push to Repository
Save your workspace state:
- From the workspace action menu, select “Versions”
- Choose the repository you configured
- Click “Push to repository”
- Enter a commit message describing your changes
- Submit to save the current state
3
Pull from Repository
Retrieve saved workspace state:
- From the workspace action menu, select “Versions”
- Choose the repository you want to pull from
- Click “Pull from repository”
- Confirm the operation
4
Exclude Files from Import
Protect specific configurations during pulls:This prevents overwriting custom configurations when pulling changes.
Deployment Methods
Built-in Deployment
Built-in Deployment
Use Prisme.ai’s built-in tools to deploy between workspaces:Export/Import Method:
- In the source workspace, go to the action menu and select “Export”
- Download the workspace archive
- In the target workspace, go to the action menu and select “Import”
- Upload the workspace archive
- Review and confirm changes
- Configure the same Git repository in both source and target workspaces
- Push from the source workspace
- Pull into the target workspace
CI/CD Integration
CI/CD Integration
Integrate with DevSecOps pipelines for automated deployment:Setup Steps:CI/CD integration provides automated, consistent deployments with added security and validation.
- Configure Git repositories for your workspaces
- Create CI/CD pipeline in your preferred system (Jenkins, GitHub Actions, etc.)
- Set up pipeline stages for testing, validation, and deployment
- Configure deployment scripts using Prisme.ai API
- Implement approval gates for production deployments
API-Based Deployment
API-Based Deployment
Create custom deployment processes using the Prisme.ai API:Key API Endpoints:API-based deployment provides the most flexibility for custom deployment workflows.
GET /workspaces/{id}/export
- Export workspacePOST /workspaces/{id}/import
- Import workspacePOST /workspaces/{id}/push
- Push to repositoryPOST /workspaces/{id}/pull
- Pull from repository
Understanding What’s Versioned
Included in Versioning
Workspace components that are saved and deployed:
- Pages and their configurations
- Blocks and custom components
- Automations and workflows
- Security roles and permissions
- App configurations
- Workspace settings
Not Included in Versioning
Data that remains specific to each environment:
- Events and their history
- Collection data
- Crawled documents
- Uploaded files
- User-specific settings
- Runtime state
The versioned content is identical to what’s included in the workspace export archive.
Environment-Specific Configuration
Manage differences between environments:1
Use Workspace Secrets
Store environment-specific values as secrets:Access these values in your application using:
2
Conditional Logic
Implement environment-aware behavior in automations:This allows your applications to adapt to different environments.
Handling Pull Results
After each import or repository pull, Prisme.ai emits aworkspaces.imported
event with details:
- Log deployment activities
- Notify team members of successful deployments
- Track errors and conflicts
- Trigger post-deployment tasks
Deployment Best Practices
Version Everything
Maintain complete history of your application:
- Commit changes frequently with clear messages
- Use branches for feature development
- Tag important releases (e.g., v1.0.0)
- Document significant version changes
- Never work directly in production
Test Before Deployment
Validate thoroughly before moving to production:
- Test in development environment first
- Verify integrations with external systems
- Test with realistic data sets
- Include user acceptance testing
- Conduct security testing
Controlled Deployment
Implement safeguards around deployment:
- Use approval workflows for production changes
- Deploy during low-traffic periods
- Implement monitoring during deployment
- Prepare rollback procedures
- Document deployment steps
Environment Isolation
Maintain clear boundaries between environments:
- Use separate API keys for each environment
- Configure different external service endpoints
- Apply appropriate security controls by environment
- Use visual indicators to distinguish environments
- Limit production access to necessary personnel
Troubleshooting Deployments
Import/Pull Failures
Import/Pull Failures
Common causes and solutions for import problems:Issue: Slug ConflictsSolution: Ensure unique slugs across workspaces or exclude index file from import.Issue: Missing DependenciesSolution: Ensure all dependencies are included in the import or available in the target workspace.Issue: Permission ErrorsSolution: Verify user has appropriate permissions in the target workspace.
Post-Deployment Issues
Post-Deployment Issues
Troubleshooting problems after deployment:Issue: Integration FailuresCauses:
- Different service endpoints in the new environment
- Missing or invalid credentials
- Network access restrictions
- Different resource allocations between environments
- Increased load in production
- Data volume differences
Rollback Procedures
Rollback Procedures
How to revert to a previous state:Git-Based Rollback:Export/Import Rollback:
- Identify the stable version tag or commit
- Pull that specific version into your workspace:
- Maintain archives of known-good workspace states
- Import the last stable archive if issues occur