Managing Environments & Apps in VS Code
The Niksphere VS Code Extension includes a dedicated sidebar in the Activity Bar with three primary tree views for managing Niksphere Cloud (Fully Managed) environments, Self-Hosted instances, and app lifecycles.
1. The Niksphere Sidebar Overview
Click the Niksphere icon in the Activity Bar to open the explorer sidebar:
- Cloud: Manage your Niksphere Cloud connection and view associated cloud instances.
- Environments: Add, authenticate, monitor, and switch between local and remote Engine environments.
- Apps: View, install, uninstall, download, and manage app packages on the currently selected environment.
2. Cloud
If your organization uses managed Niksphere Cloud instances:
- Click Log in to Niksphere Cloud in the Cloud view (or run command
Niksphere: Cloud Login). - Your browser will open for authentication via the Niksphere Cloud Broker.
- Once authenticated, all cloud environments belonging to your tenant are listed.
- Clicking a cloud instance switches the active target in the Environments and Apps views.
3. Environments
Adding an Environment
- Click the
+(Add) icon in the Environments view header. - Enter the Engine URL (e.g.
http://localhost:3000orhttps://engine.internal.company.com). - The environment is saved and displayed in the list.
Authenticating against an Environment
- Environments display
(Authenticated)with your username when logged in, or(Not Authenticated)when logged out. - Right-click an environment item and select Login to start the interactive authentication flow.
- Select Logout to invalidate and remove local session tokens from the OS keyring.
Opening the Engine Web UI
- Double-click any environment entry (or right-click $\rightarrow$ Open Frontend) to open the Niksphere Engine Web UI in your default browser.
Live Log Streaming
- Right-click an environment and select View Log (or click the
$(output)icon). - The extension opens the Niksphere Logs output channel and starts real-time log streaming (
nik env inspect monitor --stream).
4. Apps
The Apps view displays all application packages registered on the currently active environment.
Status Indicators & Badges
| Badge | Color | Meaning |
|---|---|---|
● | Green | The app version is actively installed and running. |
● | Blue | The app version is uninstalled, but persistent data/tables exist in the database. |
| (None) | Default | The package is uploaded to the engine but not installed and holds no database records. |
App Actions & Context Menu
Right-click any app or version entry to execute lifecycle commands:
1. Install App (Install)
- Installs the selected version on the engine. If schema changes exist, tables and columns are automatically provisioned.
2. Uninstall App (Uninstall)
- Stops the app and detaches its runtime logic from the engine. Database tables and user records are preserved.
3. Drop App Data (Drop Data)
- Available for uninstalled versions with existing data (blue badge).
- Prompts for confirmation before permanently dropping all tables and columns associated with that app version.
4. Download Package (Download App)
- Downloads the compiled
.nikappbinary package to your local filesystem.
5. Upload External Package (Upload)
- Click the
+(Upload) button in the Apps header to select and upload any local.nikappfile directly to the engine.
6. Delete Package (Delete)
- Deletes an uninstalled package archive permanently from the engine repository.