Module: LocalDevelopmentGateway

Defined in:
lib/local_development_gateway.rb,
lib/local_development_gateway/version.rb

Defined Under Namespace

Classes: CLI, Client, Docker, DockerError, Error

Constant Summary collapse

PROJECT_NAME =
"local-gateway"
NETWORK_NAME =
"local-gateway"
SERVICE_NAME =
"gateway"
GATEWAY_LABEL =
"local-gateway"
ASSET_ROOT =
File.expand_path("..", __dir__)
COMPOSE_FILE =
File.join(ASSET_ROOT, "docker-compose.yml")
TRAEFIK_CONFIG_FILE =
File.join(ASSET_ROOT, "config", "traefik.yml")
VERSION =
"0.1.3"

Class Method Summary collapse

Class Method Details

.ensure_running(*args) ⇒ Object



287
288
289
# File 'lib/local_development_gateway.rb', line 287

def ensure_running(*args)
  Client.new.ensure_running(*args)
end

.logs(*args) ⇒ Object



307
308
309
# File 'lib/local_development_gateway.rb', line 307

def logs(*args)
  Client.new.logs(*args, follow: true)
end

.ready?Boolean

Returns:

  • (Boolean)


299
300
301
# File 'lib/local_development_gateway.rb', line 299

def ready?
  Client.new.ready?
end

.start(*args) ⇒ Object



295
296
297
# File 'lib/local_development_gateway.rb', line 295

def start(*args)
  ensure_running(*args)
end

.statusObject



303
304
305
# File 'lib/local_development_gateway.rb', line 303

def status
  Client.new.status
end

.stop_if_unusedObject



311
312
313
# File 'lib/local_development_gateway.rb', line 311

def stop_if_unused
  Client.new.stop_if_unused
end

.with_running(ensure_running: true, &block) ⇒ Object



291
292
293
# File 'lib/local_development_gateway.rb', line 291

def with_running(ensure_running: true, &block)
  Client.new.with_running(ensure_running: ensure_running, &block)
end