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

ubuntu-ami-locator

Package Overview
Dependencies
Maintainers
2
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ubuntu-ami-locator

locate ubuntu AMI ids (ala http://cloud-images.ubuntu.com/locator/ec2/)

  • 0.1.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
2
Created
Source

ubuntu-ami-locator

Locate "official" Ubuntu AMI from javascript or the command line. This is based on the same data source as the Amazon EC2 AMI Locator. Inspired by Scott Moser's How to find the right Ubuntu AMI on EC2

Note that if all you need is the command line tool (and you are already on ubuntu), you can use the ubuntu-cloudimg-query command in the cloud-utils package.

Install

    npm install ubuntu-ami-locator

Example

From code

var locator = require("ubuntu-ami-locator");

locator.query({
    itype: "ebs",
    region: "us-west-2",
    suite: "precise",
    stream: "server",
    tag: "release",
    arch: "amd64",
    virttype: "paravirtual"
  }, function (error, data) {
      console.log(JSON.stringify(data));
  });
{
  "ami":"ami-4ad94c7a",
  "aki":"aki-fc37bacc",
  "serial":"20130222",
  ...
}

From command line (leverages some defaults)

$ ubuntu-ami-locator --itype ebs --region us-west-2 
ami-4ad94c7a

Command Line Usage

usage: node ./ubuntu-ami-locator --itype <itype> (--ec2 | --region <region>) [other arguments]

Options:
  --itype     instance-store | ebs                                    [required]
  --ec2       auto-discover region from ec2 instance meta-data         [boolean]
  --region    an AWS region, e.g. us-west-2 (required unless ec2)               
  --suite     precise | quantal | raring | etc.             [default: "precise"]
  --stream    server | desktop                               [default: "server"]
  --tag       release | daily                               [default: "release"]
  --serial    e.g. 20130222                                                     
  --arch      amd64 | i386                                    [default: "amd64"]
  --virttype  paravirtual | hvm                         [default: "paravirtual"]
  --current   consider only current releases          [boolean]  [default: true]
  --multiple  allow multiple matches (implies --json)
                                                     [boolean]  [default: false]
  --json      print full record as JSON object (or array if --multiple set).
              Default output is just AMI.            [boolean]  [default: false]

License

MIT

Keywords

FAQs

Package last updated on 22 Sep 2014

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