Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@pulumi/random

Package Overview
Dependencies
Maintainers
2
Versions
513
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pulumi/random

A Pulumi package to safely use randomness in Pulumi programs.

  • 0.2.1-dev.1543204081
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
437K
decreased by-8.38%
Maintainers
2
Weekly downloads
 
Created

What is @pulumi/random?

@pulumi/random is an npm package that provides utilities for generating random values, such as random strings, random integers, and random passwords. It is particularly useful in infrastructure as code (IaC) scenarios where you need to generate random values for resource names, passwords, or other configurations.

What are @pulumi/random's main functionalities?

Random String

Generates a random string of specified length. In this example, a random string of length 16 is generated without special characters.

const pulumi = require('@pulumi/pulumi');
const random = require('@pulumi/random');

const randomString = new random.RandomString('randomString', {
  length: 16,
  special: false,
});

exports.result = randomString.result;

Random Integer

Generates a random integer within a specified range. In this example, a random integer between 1 and 100 is generated.

const pulumi = require('@pulumi/pulumi');
const random = require('@pulumi/random');

const randomInteger = new random.RandomInteger('randomInteger', {
  min: 1,
  max: 100,
});

exports.result = randomInteger.result;

Random Password

Generates a random password of specified length. In this example, a random password of length 20 is generated with special characters included.

const pulumi = require('@pulumi/pulumi');
const random = require('@pulumi/random');

const randomPassword = new random.RandomPassword('randomPassword', {
  length: 20,
  special: true,
});

exports.result = randomPassword.result;

Other packages similar to @pulumi/random

Keywords

FAQs

Package last updated on 26 Nov 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc