Create a New Project

Let’s get started with a new project in a new directory.

$ mkdir quickstart && cd quickstart
$ pulumi new azure-javascript
$ mkdir quickstart && cd quickstart
$ pulumi new azure-typescript
$ mkdir quickstart && cd quickstart
$ pulumi new azure-python

If this is your first time running pulumi new (or most other pulumi commands), you will be prompted to login to the Pulumi service. The CLI works in tandem with the Pulumi service to deliver a reliable experience, and is free for individual use, with additional features available for teams. Hitting enter at the prompt will open a web browser allowing you to sign in or sign up. Alternatively, you may login or logout explicitly if you prefer. See the FAQ for more information.

After logging in, the CLI will proceed with walking you through creating a new project.

This command will walk you through creating a new Pulumi project.

Enter a value or leave blank to accept the (default), and press <ENTER>.
Press ^C at any time to quit.

project name: (quickstart)
project description: (A minimal Azure Pulumi program)
Created project 'quickstart'

stack name: (dev)
Created stack 'dev'

azure:environment: The Azure environment to use (`public`, `usgovernment`, `german`, `china`): (public)
Saved config

First, you will be asked for a project name and description. You can hit enter to accept the default values or enter a new values.

Next, you will be asked for the name of a stack. You can hit enter to accept the default value of dev.

What are projects and stacks? Pulumi projects and stacks are a way to organize Pulumi code. You can consider a Pulumi Project to be analogous to a GitHub repo: a single place for code — and a Stack to be an instance of that code which has separate configuration. For instance, Project Foo may have multiple stacks for Dev, Test, Prod, or perhaps for different cloud configurations (e.g. geographic region). Please see this guide for some best practices on organizing your Pulumi projects and stacks.

Next, you will be prompted for some configuration values for the stack.

For Azure projects, you will be prompted for the Azure environment. You can accept the default value of public or choose another environment.

After some dependency installations from npm, the project and stack will be ready.

After some dependency installations from npm, the project and stack will be ready.

After the command completes, the project and stack will be ready.

Next, we’ll review the generated project files.