Sha256: 5080263cfdd4c4f617bd31c9c53ee1dd96f0699fc194b86e5e65ef97c3e5d8ad

Contents?: true

Size: 1014 Bytes

Versions: 32

Compression:

Stored size: 1014 Bytes

Contents

require 'thor/shell'
require 'docker-sync/execution'

module DockerSync
  module WatchStrategy
    class Remote_logs
      include Thor::Shell
      include Execution

      @options
      @sync_name
      @watch_fork
      @watch_thread

      def initialize(sync_name, options)
        @options = options
        @sync_name = sync_name
        @watch_fork = nil
        @watch_thread = nil
        @unison = DockerSync::SyncStrategy::NativeOsx.new(@sync_name, @options)
      end

      def run
        say_status 'success', "Showing unison logs from your sync container: #{@unison.get_container_name}", :green
        cmd = "docker exec #{@unison.get_container_name} tail -F /tmp/unison.log"
        @watch_thread = thread_exec(cmd, 'Sync Log:')
      end

      def stop
      end

      def clean
      end

      def watch
      end

      def watch_options
      end

      def watch_fork
        return @watch_fork
      end

      def watch_thread
        return @watch_thread
      end
    end
  end
end

Version data entries

32 entries across 32 versions & 1 rubygems

Version Path
docker-sync-1.0.5 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-1.0.4 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-1.0.3 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-1.0.2 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-1.0.1 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-1.0.0 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.7.2 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.7.1 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.7.0 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.6.0 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.14 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.13 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.11 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.11.pre.beta3 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.11.pre.beta2 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.11.pre.beta1 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.10 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.10.pre.beta1 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.9 lib/docker-sync/watch_strategy/remotelogs.rb
docker-sync-0.5.8 lib/docker-sync/watch_strategy/remotelogs.rb