Raseef Environment Variables: Save, Deploy or Restart?

Learn when Raseef applies environment variables, how service references resolve, and how to troubleshoot stale values and connection errors without exposing secrets.

You updated DATABASE_URL or an external API key in the console, but your application still behaves as if nothing changed. Before changing code or restarting the database, distinguish three things: saved configuration, values resolved at deployment, and the revision currently running.

This guide is for developers who already have an app on Raseef and need to change or troubleshoot its configuration. If you are deploying for the first time, start with the GitHub deployment guide.

The core rule: saving is not deploying

According to the variable documentation, variables apply on the next deployment. Saving a value does not restart the running revision, and restarting that revision keeps its current values.

ActionResult
Save a variableSaves configuration for the next deployment; leaves the running app unchanged
Deploy saved configurationStarts a revision with values resolved at deployment
Restart the running revisionKeeps its current values; does not apply pending saved changes
Roll back to a previous revisionUses the values saved with that deployment

Check the saved and running revisions in the service panel, deploy the change, and follow Deployments and Logs. A successful save does not prove your application has received the new value.

Reference services instead of copying connection details

Suppose your application and a PostgreSQL service named db are in the same environment. In the application's Variables, add:

DATABASE_URL=${{ db.DATABASE_URL }}

This is a reference interpreted by Raseef in variable settings, not a command to run in a shell. When your application deploys, Raseef replaces it with the connection string supplied by the database template.

Reference rules matter:

  • The source and consuming services must be in the same environment.
  • A service can reference another service, not itself.
  • References are one level deep; do not chain references through other references.
  • Deploy the source service first when you need a variable from its last deployed revision.

References are stored by service identity, so renaming a service does not break them. For private addresses, prefer references over manually copying hostnames.

What if a value changes in the source service?

Changing a referenced value in another service does not automatically redeploy the consuming app. The console shows which sources changed; you deploy the consumer when ready.

A suggested sequence:

  1. Make and deploy the required change in the source service.
  2. Review the services that depend on that value.
  3. Deploy each consumer that needs the update.
  4. Test a real operation that uses the connection, such as reading a test record.
  5. Monitor errors without logging the connection string or key.

For credential rotation, plan the transition too: running application instances may still use the old value. Changing a variable containing a password does not by itself prove that the password inside the database system has changed; follow that service's rotation procedure.

This is operational guidance, not a guarantee that every secret can be rotated without interruption.

Node.js example: check configuration without exposing it

Validate required variables early in your application's entry point. This example uses built-in Node.js functionality and needs no additional package:

const required = ['DATABASE_URL'];
const missing = required.filter(
  (name) => !process.env[name]?.trim()
);

if (missing.length > 0) {
  console.error('Missing required configuration:', missing.join(', '));
  process.exit(1);
}

console.info('Required configuration is present');

The example logs only the names of missing variables. It does not validate credentials or establish a database connection. Add a connection check appropriate to your database library; a present variable is not a substitute.

Do not dump the entire process.env object while debugging. The documentation describes conditions and limitations for log masking. Treat it as a safety net, not permission to print sensitive values.

A practical troubleshooting table

SymptomWhat to checkNext step
The old value is still in useDid you only save or choose Restart?Deploy saved configuration and test behavior
A reference fails to resolve during deploymentReference name, environment and source deploymentCorrect the reference and deploy the source before the consumer
The variable exists but the connection failsDatabase status, private port and credential validityInvestigate networking separately from authentication
The app connects but your laptop cannotAre you using the private address?Test from a service inside the same environment
Authentication fails after rollbackDoes the old revision use a revoked secret?Check credential compatibility before relying on rollback

Private addresses are reachable by services in the same environment, not by the internet or other projects and environments. An unsuccessful connection from your laptop does not necessarily mean the database is down. See the private networking documentation.

Before using the raw editor or rolling back

The Raw editor applies the list as saved: removing a line deletes that variable, and the last value wins if a name appears twice. Review changes before saving, particularly when pasting a complete .env file.

Rollback restores an earlier service image and settings. It does not restore database contents or make a revoked credential valid again. If you changed the database schema or invalidated an external key, verify that the old application revision can still operate. See the deployment and rollback guide.

A checklist for your next configuration change

  • Document required variable names in .env.example without real secrets.
  • Confirm the target service and environment before saving.
  • Deploy the change; saving or restarting alone is not enough.
  • Test a feature that depends on the value, not just the service's running status.
  • Verify that rollback remains compatible with current credentials and the database schema.

The useful mental model is simple: configuration belongs to a deployment, rather than instantly changing inside a running process. That makes configuration incidents easier to diagnose and avoids unnecessary restarts.

Request access to the Raseef private pilot to manage your application and its services from one console. Raseef is currently onboarding a limited number of teams through its private pilot.