Zum Hauptinhalt springen
ProdukteDesktop-WerkzeugeTASTECADZeichnungsprüfungTASTEFILESDateiverwaltungTASTEFTPDateiübertragungTASTESSHRemote-ArbeitsbereichTASTEZIPKomprimieren und EntpackenTASTEWINMDateiverwaltungEntwicklerwerkzeugeTASTECODEIntegrierte Entwicklungsumgebung für RustTASTESTUDIOIntegrierte Entwicklungs- und TestumgebungTASTEETLDatenintegration (ETL)ServerTASTEREMOTERemote-Desktop-ServerTASTEGEOGeodatenserverTASTEMAILE-Mail-ArbeitsbereichInvestierenTASTESTOCKDesktop-App für automatischen AktienhandelErste SchritteDownloadsDokumentationKaufenAlle Produkte
Marktplatz
Neuigkeiten
TechnikNeuigkeitenEntwickler-News von heuteEntwicklerdokuProgrammiersprachenRustTypeScriptJavaScriptPythonGoC#JavaCC++KotlinDartWeb-Frontend-FrameworksNext.jsReactVue.js · NuxtSvelteKitAngularServer-FrameworksSpring BootDjangoFastAPIASP.NET CoreNestJS · ExpressApp- & Desktop-FrameworksTauriFlutterReact NativeElectronAlgorithmenAlgorithmus-GrundlagenKernalgorithmenFortgeschrittene AlgorithmenAlgorithmen für die Praxis
CommunityProjekteEntwicklungslogsPromptsProbleme mit KI-ToolsShowcaseCommunity-Leitfaden
ZusammenarbeitWissenstransferWebsite-AufbauDesktop-App-AufbauRelease- und ZahlungspipelineVertriebspartnerKontakt
DiensteRemote-DesktopIndividuelle Installationspakete
TASTEDEV
Produkte

Desktop-Werkzeuge

TASTECADKomplexe Zeichnungen, mühelos geöffnetTASTEFILESNur die Dateien, die zählen – in BestzeitTASTEFTPDer aufgeräumteste Weg für Ihre DateienTASTESSHDie stärkere Verbindung zu Ihren ServernTASTEZIPSchneller packen, sicherer entpackenTASTEWINMEin tastaturorientierter Dateimanager mit zwei Fenstern

Entwicklerwerkzeuge

TASTECODERust-Apps bearbeiten, bauen, debuggen und testen – alles in einem FensterTASTESTUDIOVom Bearbeiten bis zu Remote-Tests und freigegebenen KI-KorrekturenTASTEETLDaten bewegen, die Werte im Blick

Server

TASTEREMOTEEin Remote-Desktop auf Ihrem eigenen ServerTASTEGEOEin GeoServer-kompatibler Geodatenserver, neu aufgebaut in RustTASTEMAILIhre E-Mail wieder in Ihrer Hand

Investieren

TASTESTOCKAutomatischer Aktienhandel nach Ihren Regeln: wann und was

Erste Schritte

DownloadsNeueste Versionen aller ProdukteDokuSo nutzen Sie jedes ProduktKaufenAbos und DauerlizenzenAlle ProdukteAlle Produkte im Überblick
Alle Produkte
MarktplatzNeuigkeiten
Technik

Neuigkeiten

Entwickler-News von heuteOffizielle Meldungen zu Sprachen, Frameworks, GitHub und KIEntwicklerdokuAnleitungen zu Sprachen, Frameworks und Algorithmen

Programmiersprachen

RustTypeScriptJavaScriptPythonGoC#JavaCC++KotlinDart

Frameworks

Web-Frontend-FrameworksNext.jsReactVue.js · NuxtSvelteKitAngular
Server-FrameworksSpring BootDjangoFastAPIASP.NET CoreNestJS · Express
App- & Desktop-FrameworksTauriFlutterReact NativeElectron

Algorithmen

Algorithmus-GrundlagenKomplexitätsanalyse · Sortieren · Suchen · Grundlegende Datenstrukturen · Bäume und HeapsKernalgorithmenGraphtraversierung · Kürzeste Wege und minimale Spannbäume · Dynamische Programmierung · Greedy-Algorithmen · Teile und herrsche · BacktrackingFortgeschrittene AlgorithmenZeichenkettenalgorithmen · Mathematik und Zahlentheorie · Bitmanipulation · Segmentbäume · Union-FindAlgorithmen für die PraxisStrategie für Coding-Interviews · LRU-Cache · Rate Limiting · Konsistentes Hashing
Alle Entwicklungsdokumente
Community
ProjekteEntwickler und Projekte entdeckenEntwicklungslogsEntscheidungen und ErkenntnissePromptsWiederverwendbare AnweisungenProbleme mit KI-ToolsProbleme und Workarounds für Claude, Codex, GeminiShowcaseFertige ErgebnisseCommunity-LeitfadenWie wir offen entwickeln
Zusammenarbeit
WissenstransferNative Apps mit Rust und eguiWebsite-Aufbau10 Sprachen, Konten, Dokumentation und DownloadsDesktop-App-AufbauRust und egui, ohne WebViewRelease- und ZahlungspipelineSignatur, MSI, deb, rpm, AppImage, PrüfsummenVertriebspartnerEmpfehlen und 30 % erhaltenKontaktEntwicklung, Partnerschaft, Investition
Dienste
Remote-DesktopIhren Computer im Browser erreichenIndividuelle InstallationspaketeNur nötige Funktionen, Einstellungen vorab
Kaufen
DE
한국어EnglishDeutschEspañolFrançaisItalianoPortuguês (Brasil)日本語简体中文繁體中文
Anmelden
Anmelden
TASTEDEV

Von kleinen Werkzeugen zu besserer Entwicklung.

support@tastedev.netTASTEDEV unterstützen
ProdukteProduktübersichtKaufenDokuDownloadsMarktplatzSupport
CommunityProjekteEntwicklungslogsPromptsProbleme mit KI-ToolsShowcase
RichtlinienÜber unsDatenschutzerklärungNutzungsbedingungenAbo-BedingungenRückerstattungCommunity-Richtlinien
KontoAnmeldenRegistrieren
Besucher
Heute
Gestern
Aufrufe gesamt
Firma
GXSOFT
Vertretungsberechtigt
CHOI YOUNG GU
Handelsregisternummer
853-44-00368
Anschrift
9F V24, 351 Gyeongin-ro, Michuhol-gu, Incheon, Republic of Korea
Telefon
+82-10-4404-1523
E-Mail
whitecalvin@tastedev.net
Datenschutzbeauftragter
CHOI YOUNG GU

© 2026 TASTEDEVProduktinformationen basieren auf verifizierten Entwicklungsquellen.Veröffentlicht · wird verbessert

NestJS · Express-Dokumentation
NestJS · Express
Getting Started with NestJS and ExpressProject StructureCore ConceptsValidation, Configuration and DatabasesTestingDeployment
Diskussionen

NestJS · Express-Anleitung · 6/6

Deployment

Dieses Kapitel ist vorerst nur auf Englisch verfügbar.

A Nest application is an ordinary Node.js server: you compile TypeScript to JavaScript and run dist/main.js with Node. This chapter covers production builds, environment configuration, and deploying with a process manager or containers. Express apps deploy the same way.

Production build

npm run build runs nest build, compiling src into dist. The output runs on plain Node.js without the Nest CLI.

npm ci
npm run build
NODE_ENV=production node dist/main
# or the generated script
npm run start:prod

Production servers do not need dev dependencies: remove them after building with npm prune --omit=dev, or install with npm ci --omit=dev. Avoid running production with ts-node or nest start. An Express app without a compile step simply runs as node src/server.js.

Production configuration

Keep configuration out of code and pass it as environment variables: the port via PORT, database URLs and secrets via your platform's secret store or environment settings. Never bake a .env file into an image or repository. A production main.ts typically adds the following.

// src/main.ts
import { ValidationPipe } from "@nestjs/common";
import { NestFactory } from "@nestjs/core";
import helmet from "helmet";
import { AppModule } from "./app.module";

async function bootstrap() {
  const app = await NestFactory.create(AppModule);
  app.use(helmet()); // security-related HTTP headers
  app.enableCors({ origin: process.env.CORS_ORIGIN });
  app.useGlobalPipes(new ValidationPipe({ whitelist: true }));
  app.enableShutdownHooks(); // clean up on SIGTERM
  await app.listen(process.env.PORT ?? 3000, "0.0.0.0");
}
bootstrap();

helmet (installed with npm i helmet) is Express middleware, and Nest uses it as is through app.use(). With enableShutdownHooks(), lifecycle hooks such as onModuleDestroy run when the container sends a termination signal, so database connections close cleanly. Behind a reverse proxy, enable Express's trust proxy setting to read the real client IP and protocol; in Nest, create the app with NestFactory.create<NestExpressApplication>() and call app.set("trust proxy", 1).

Running under a process manager

On a VM or bare server, you need something that restarts the process if it dies. PM2 is a popular Node.js process manager and can run one process per CPU core in cluster mode.

npm i -g pm2
pm2 start dist/main.js --name api -i max
pm2 logs api
pm2 save      # remember the current process list
pm2 startup   # start automatically after a reboot
Fragen zu diesem Kapitel?
Vorheriges KapitelTesting

A systemd service running node dist/main.js is another common choice. Put a reverse proxy such as Nginx in front to handle TLS and static files.

Deploying with containers

Containers let the same image run anywhere. A multi-stage Dockerfile separates the build from the runtime and keeps the image small.

FROM node:lts-alpine AS build
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build && npm prune --omit=dev

FROM node:lts-alpine
WORKDIR /app
ENV NODE_ENV=production
COPY --from=build /app/package*.json ./
COPY --from=build /app/node_modules ./node_modules
COPY --from=build /app/dist ./dist
USER node
EXPOSE 3000
CMD ["node", "dist/main.js"]

List node_modules, dist, .env and .git in .dockerignore to keep the build context small and secrets out of the image. Inside a container, run node directly rather than PM2, and leave restarts and replicas to Docker, Kubernetes or your cloud's container service.

docker build -t my-api .
docker run -p 3000:3000 -e DATABASE_URL="postgres://user:pass@db:5432/app" my-api

Pre-deployment checklist

  1. Make sure npm run build and the test suites pass in CI.
  2. Validate required environment variables at startup, for example with the validate option of ConfigModule.forRoot.
  3. Run database migrations as part of the release and keep synchronize off.
  4. Expose a health check endpoint for load balancers and orchestrators (Nest offers @nestjs/terminus).
  5. Log to standard output and let the platform collect the logs.

Summary

  • Build dist with npm run build, run it with node dist/main, and ship only production dependencies.
  • Supply configuration through environment variables and add production settings such as Helmet, CORS and shutdown hooks in main.ts.
  • Use PM2 or systemd on servers, and a multi-stage Dockerfile for containers.
  • Express apps follow the same principles: environment variables, process management and containers.

Official documentation

  • NestJS Documentation
  • NestJS First steps
  • Nest CLI
  • NestJS Deployment
  • Express
  • Express production best practices

0 Kommentare

Top-KommentareNeueste zuerst

Anmelden · Melde dich an, um einen Kommentar zu schreiben.