New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

dslimple

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dslimple

  • 2.0.7
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

DSLimple

After DSLimple

DSLimple is a tool to manage DNSimple.

It defines the state of DNSimple using DSL, and updates DNSimple according to DSL.

Installation

Add this line to your application's Gemfile:

gem 'dslimple'

And then execute:

$ bundle

Or install it yourself as:

$ gem install dslimple

Usage

export DSLIMPLE_EMAIL="..."
export DSLIMPLE_API_TOKEN="..."
dslimple export -f Domainfile
vi Domainfile
dslimple apply --dry-run -f Domainfile
dslimple apply --yes -f Domainfile

Help

$ dslimple help
Commands:
  dslimple apply           # Apply domain specifications
  dslimple export          # Export domain specifications
  dslimple help [COMMAND]  # Describe available commands or one specific command

Options:
  -e, [--email=EMAIL]                 # Your E-Mail address
  -t, [--api-token=API_TOKEN]         # Your API token
  -dt, [--domain-token=DOMAIN_TOKEN]  # Your Domain API token
      [--sandbox], [--no-sandbox]     # Use sandbox API(at sandbox.dnsimple.com)
                                      # Default: true
      [--debug], [--no-debug]
help apply
$ dslimple help apply
Usage:
  dslimple apply

Options:
  -o, [--only=one two three]                 # Specify domains for apply
  -d, [--dry-run], [--no-dry-run]
  -f, [--file=FILE]                          # Source Domainfile path
                                             # Default: Domainfile
      [--addition], [--no-addition]          # Add specified records
                                             # Default: true
      [--modification], [--no-modification]  # Modify specified records
                                             # Default: true
      [--deletion], [--no-deletion]          # Delete unspecified records
                                             # Default: true
  -y, [--yes], [--no-yes]                    # Do not confirm on before apply
  -e, [--email=EMAIL]                        # Your E-Mail address
  -t, [--api-token=API_TOKEN]                # Your API token
  -dt, [--domain-token=DOMAIN_TOKEN]         # Your Domain API token
      [--sandbox], [--no-sandbox]            # Use sandbox API(at sandbox.dnsimple.com)
                                             # Default: true
      [--debug], [--no-debug]

Apply domain specifications
help export
$ dslimple help export
Usage:
  dslimple export

Options:
  -o, [--only=one two three]             # Specify domains for export
  -f, [--file=FILE]                      # Export Domainfile path
                                         # Default: Domainfile
  -d, [--dir=DIR]                        # Export directory path for split
                                         # Default: ./domainfiles
  -s, [--split], [--no-split]            # Export with split by domains
  -m, [--modeline], [--no-modeline]      # Export with modeline for Vim
      [--soa-and-ns], [--no-soa-and-ns]  # Export without SOA and NS records
  -e, [--email=EMAIL]                    # Your E-Mail address
  -t, [--api-token=API_TOKEN]            # Your API token
  -dt, [--domain-token=DOMAIN_TOKEN]     # Your Domain API token
      [--sandbox], [--no-sandbox]        # Use sandbox API(at sandbox.dnsimple.com)
                                         # Default: true
      [--debug], [--no-debug]

Export domain specifications

Domainfile Examples

Basic

The following defines are all the same meaning

domain "example.com" do
  a_record ttl: 3600 do
    "0.0.0.0"
  end

  record type: :a, ttl: 3600 do
    "0.0.0.0"
  end

  a_record do
    ttl 3600
    content "0.0.0.0"
  end
end

Dynamic

DSLimple's DSL works on ruby.

require 'open-uri'
require 'json'

domain "example.internal" do
  JSON.parse(open('http://my.internal.service/records.json', &:read)).each do |record_data|
    recored record_data['name'], record_data['options'] { record_data['content'] }
  end
end

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/zeny-io/dslimple.

License

The gem is available as open source under the terms of the MIT License.

Inspired by

FAQs

Package last updated on 12 Jun 2021

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