Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/knownasilya/aws-subdomain
Create subdomains for AWS without diving into the AWS SDK
https://github.com/knownasilya/aws-subdomain
aws dns nodejs route53 subdomain
Last synced: 9 days ago
JSON representation
Create subdomains for AWS without diving into the AWS SDK
- Host: GitHub
- URL: https://github.com/knownasilya/aws-subdomain
- Owner: knownasilya
- License: isc
- Created: 2014-11-18T20:45:55.000Z (almost 10 years ago)
- Default Branch: main
- Last Pushed: 2023-01-06T18:22:28.000Z (almost 2 years ago)
- Last Synced: 2024-10-25T13:17:36.030Z (23 days ago)
- Topics: aws, dns, nodejs, route53, subdomain
- Language: JavaScript
- Size: 589 KB
- Stars: 8
- Watchers: 3
- Forks: 3
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# aws-subdomain
Create subdomains for AWS without diving into the AWS SDK
[![NPM][npm-badge]][npm-badge-url]
[![Build Status][travis-badge]][travis-badge-url]
[![Coverage Status][coveralls-badge]][coveralls-badge-url]## Usage
First install this module with `npm install aws-subdomain --save`.
```js
var subdomain = require('aws-subdomain')({
accessKeyId: 'your-id-here',
secretAccessKey: 'your-secret-here',
});subdomain.create('i.wear.sho.es', function (err, result) {
// handle error/result
});subdomain.delete('i.wear.sho.es', function (err, result) {
// handle error/result
});
```We will find the correct HostedZoneId based on the root domain, e.g. 'sho.es'
and will create/delete the subdomain for you.## CLI
```shell
npm install aws-subdomain -g
aws-subdomain new.shiny.po.ny -i [awsAccessKeyId] -s [awsSecretAccessKey]
```Can also pass `-a` with 'upsert', or 'delete'. The default is to 'create'.
By default the AWS credentials come from environment variables
`AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY`, but can be
overridden with `-i` and `-s` respectively.## Test
```shell
npm test
# or for TAP output
node test
```## TODO
- Add event for completion of change
- Add upsert functions
- Support promises
- Add default `baseDomain` to options/integrate with actions.[travis-badge-url]: https://travis-ci.org/knownasilya/aws-subdomain
[travis-badge]: https://travis-ci.org/knownasilya/aws-subdomain.svg?branch=master
[npm-badge-url]: https://nodei.co/npm/aws-subdomain/
[npm-badge]: https://nodei.co/npm/aws-subdomain.png?downloads=true&stars=true
[coveralls-badge]: https://coveralls.io/repos/knownasilya/aws-subdomain/badge.svg?branch=master
[coveralls-badge-url]: https://coveralls.io/r/knownasilya/aws-subdomain?branch=master