-
Notifications
You must be signed in to change notification settings - Fork 1.2k
[New] Getting Started with Pulumi #2553
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Highlights of edit: - Added list numbering to the instructions - Added more section headers to break up longer sections - Reworded intro sentence that was a little too close to a post on the blog of Pulumi's CEO - Added notes with brief descriptions of some Pulumi concepts that were mentioned - Spelling/style fixes - Made example JavaScript variable names more verbose for increased legibility - Addressed some inconsistencies in letter case and naming for JavaScript variables - Updated the StackScript so that it makes a custom index page on each web backend based on the hostname of the Linode. Also removed the line that updated /etc/hosts, because I think it's incorrect to tie 127.0.0.1 to the hostname - Cut out adverbs/extra clauses to tighten up the text
| stackscript: StackScript | ||
| typescript: TypeScript | ||
| pulumi: Pulumi | ||
| markdown: Markdown |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressing a merge conflict in Terms.yml
|
|
||
| --- | ||
|
|
||
| **Pulumi** is a multi-language, multi-cloud, and fully extensible development platform. By using Pulumi for your chosen programming language, you can begin using code that can manage your account similarly to our [API](https://developers.linode.com/api/v4/) or [CLI](https://www.linode.com/docs/platform/api/using-the-linode-cli/). Though this guide will focus on `Javascript`, Pulumi is also compatible with `Go`, `Python`, and `Typescript`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The first sentence was too close to a sentence used in this post by the CEO of Pulumi:
http://joeduffyblog.com/2018/06/18/hello-pulumi/
"Pulumi is multi-language, multi-cloud, and fully extensible."
Got nervous about possible plagiarism concerns, so I updated that sentence. Also added an explanation of how Pulumi is an example of an IaC tool to draw parallels in case the the reader may already be familiar with another IaC tool.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, only bits of code or terminal output need to be rendered in backticks, so I removed them from the names of the languages
|
|
||
| With Pulumi's Linode integration, you can manage your Linode resources as you would with our [API](https://developers.linode.com/api/v4/) or [CLI](/docs/platform/api/using-the-linode-cli/), but in a language you may already be familiar with. This guide will present examples written in JavaScript, but Pulumi is also compatible with Go, Python, and TypeScript. | ||
|
|
||
| Pulumi also comes with a CLI interface for running the cloud infrastructure programs that you write. Once you've written a program, you can create your cloud resources with a single command: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Inserted this paragraph and CLI example so that we could get in an example of code/commands early on, which could hopefully help with reader engagement
| * Install and set up Pulumi on Debian9 | ||
| * Create a Linode using Pulumi and Javascript | ||
| * Create a configured Nodebalancer with a working NGINX server pre-installed using Pulumi and Javascript | ||
| * [Install and set up Pulumi](#before-you-begin) on Debian 9 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Distros should be "Distro_name distro_version" (space in between)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also added links to the respective sections
|
|
||
| ## Before You Begin | ||
|
|
||
| 1. If you haven't yet, [create a Linode API token](https://www.linode.com/docs/platform/api/getting-started-with-the-linode-api/#create-an-api-token). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Links to other guides should be relative
| 1. [Create a free Pulumi account](https://app.pulumi.com/signup). | ||
|
|
||
| 1. Create a new Debian9 Linode configured following our [Getting Started](https://www.linode.com/docs/getting-started/) and [Securing Your Server](https://www.linode.com/docs/security/securing-your-server/) guide. | ||
| 1. Create a new Debian 9 Linode. Follow our [Getting Started](/docs/getting-started/) to deploy the Linode, and then follow the [Securing Your Server](/docs/security/securing-your-server/) guide. Be sure to create a [limited Linux user with sudo privileges](/docs/security/securing-your-server/#add-a-limited-user-account) on your server. All commands in this guide are to be run from a sudo user. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding a sentence emphasizing the importance of creating a limited sudo user
| pulumi up | ||
| pulumi up | ||
|
|
||
| As before, select "yes" when prompted and wait for a few moments as your resources are created, configured, and brought online. Once the process is completed, you'll see your Nodebalancer's IP address and the port you configured earlier displayed as part of the output. Enter this IP address and port into your web browser, and you will see a default nginx page confirming the installation was successful. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Moved second sentence into a separate step (which is the next step)
|
|
||
| {{< note >}} | ||
| If you are not able to see the default nginx page right away, you should wait a few additional moments. NodeBalancers can sometimes require a little extra time to fully apply a new configuration. | ||
| 1. Once the process is completed, you'll see your NodeBalancer's IP address and the port you configured earlier displayed as part of the output: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Showing the Pulumi variable exports the reader should look for in the output, and giving an example of the response via cURL
| {{< /file >}} | ||
|
|
||
| The file requires two JavaScript packages unique to Pulumi: Pulumi's SDK, and Pulumi's Linode integration. [Pulumi's API Reference Documentation](https://pulumi.io/reference/pkg/nodejs/pulumi/linode/) serves as a reference for the JavaScript you'll see here. It also includes a library of several additional options that enable you to create configurations more specific to your use case. | ||
| The file requires two JavaScript modules unique to Pulumi: Pulumi's SDK, and Pulumi's Linode integration. [Pulumi's API Reference Documentation](https://pulumi.io/reference/pkg/nodejs/pulumi/linode/) serves as a reference for the JavaScript you'll see here. It also includes a library of several additional options that enable you to create configurations more specific to your use case. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reverting previous package<->module change
| PATH=$PATH:/home/username/.pulumi/bin | ||
|
|
||
| 1. Install [node.js](https://nodejs.org/en/) and [npm](https://www.npmjs.com/): | ||
| 1. Install [Node.js](https://nodejs.org/en/) and [npm](https://www.npmjs.com/): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Vale fix
| author: | ||
| name: Linode | ||
| email: docs@linode.com | ||
| description: 'Basic instructions to set install Pulumi and create a configured NodeBalancer through code.' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was a little awkward, reworded it
No description provided.