Module: Dkron

Defined in:
lib/dkron-rb/version.rb,
lib/dkron.rb,
lib/dkron-rb.rb,
lib/dkron-rb/cron.rb,
lib/dkron-rb/api_error.rb,
lib/dkron-rb/api_client.rb,
lib/dkron-rb/models/job.rb,
lib/dkron-rb/models/serf.rb,
lib/dkron-rb/models/tags.rb,
lib/dkron-rb/api/jobs_api.rb,
lib/dkron-rb/models/agent.rb,
lib/dkron-rb/configuration.rb,
lib/dkron-rb/models/member.rb,
lib/dkron-rb/models/status.rb,
lib/dkron-rb/api/default_api.rb,
lib/dkron-rb/api/members_api.rb,
lib/dkron-rb/numeric_seconds.rb,
lib/dkron-rb/models/execution.rb,
lib/dkron-rb/models/processors.rb,
lib/dkron-rb/api/executions_api.rb,
lib/dkron-rb/models/processor_log.rb,
lib/dkron-rb/models/executor_shell.rb,
lib/dkron-rb/models/executor_config.rb,
lib/dkron-rb/models/processor_files.rb,
lib/dkron-rb/models/processor_syslog.rb,
lib/dkron-rb/models/inline_response_200.rb

Overview

#Dkron REST API

#You can communicate with Dkron using a RESTful JSON API over HTTP. Dkron nodes usually listen on port ‘8080` for API requests. All examples in this section assume that you’ve found a running leader at ‘localhost:8080`. Dkron implements a RESTful JSON API over HTTP to communicate with software clients. Dkron listens in port `8080` by default. All examples in this section assume that you’re using the default port. Default API responses are unformatted JSON add the ‘pretty=true` param to format the response.

OpenAPI spec version: 0.11.2

Generated by: github.com/swagger-api/swagger-codegen.git Swagger Codegen version: 2.3.1

Defined Under Namespace

Modules: Output Classes: Agent, ApiClient, ApiError, Configuration, DefaultApi, Execution, ExecutionsApi, ExecutorConfig, ExecutorShell, InlineResponse200, Job, JobsApi, Member, MembersApi, NumericSeconds, ProcessorFiles, ProcessorLog, ProcessorSyslog, Processors, Serf, Status, Tags

Constant Summary collapse

VERSION =
"0.11.2"

Class Method Summary collapse

Class Method Details

.configureObject

Customize default settings for the SDK using block.

Dkron.configure do |config|
  config.username = "xxx"
  config.password = "xxx"
end

If no block given, return the default Configuration object.



41
42
43
44
45
46
47
# File 'lib/dkron-rb.rb', line 41

def configure
  if block_given?
    yield(Configuration.default)
  else
    Configuration.default
  end
end

.seconds(number, units) ⇒ Object



6
7
8
# File 'lib/dkron.rb', line 6

def self.seconds(number, units)
  Dkron::NumericSeconds.seconds(number, units)
end