teracyhq / dev

The only truly universal productive development platform with Docker on macOS, Linux and Windows! http://blog.teracy.com/2016/12/20/teracy-dev-the-only-truly-universal-productive-development-platform-with-docker-on-macos-linux-and-windows/ http://slides.teracy.net/hoatle/productive-dev-workflow-with-teracy-dev/latest/
http://dev.teracy.org/docs
BSD 3-Clause "New" or "Revised" License
86 stars 31 forks source link

should find a way for git-sync to work with passphrase ssh key #610

Open hoatle opened 4 years ago

hoatle commented 4 years ago

try to sync git repo with passphrase ssh key and make sure it works

hoatle commented 4 years ago

related error when $ cd ~/xxx-dev && vagrant status

C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/logging/mask_filter.rb:38:in `block in masked'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/set.rb:324:in `each_key'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/set.rb:324:in `each'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/logging/mask_filter.rb:36:in `masked'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/logging/mask_filter.rb:28:in `filtered'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/logging.rb:62:in `block (2 levels) in configure_logger_for'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/logging.rb:61:in `each'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/logging.rb:61:in `block in configure_logger_for'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/logger.rb:582:in `format_message'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/logger.rb:470:in `add'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/logger.rb:534:in `warn'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/location/git_synch.rb:21:in `rescue in sync'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/location/git_synch.rb:17:in `sync'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/location/manager.rb:19:in `block in sync'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/location/manager.rb:18:in `each'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/location/manager.rb:18:in `sync'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/loader.rb:127:in `sync_teracy_dev_entry'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/loader.rb:49:in `sync'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev/loader.rb:32:in `start'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev.rb:37:in `<module:TeracyDev>'
C:/cygwin64/home/user/xxx-dev/lib/teracy-dev.rb:11:in `<top (required)>'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/cygwin64/home/user/xxx-dev/Vagrantfile:21:in `<top (required)>'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config/loader.rb:239:in `load'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config/loader.rb:239:in `block in procs_for_path'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config.rb:53:in `block in capture_configures'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config.rb:48:in `synchronize'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config.rb:48:in `capture_configures'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config/loader.rb:237:in `procs_for_path'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config/loader.rb:223:in `procs_for_source'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config/loader.rb:67:in `block in set'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config/loader.rb:61:in `each'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/config/loader.rb:61:in `set'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/environment.rb:489:in `config_loader'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/environment.rb:794:in `vagrantfile'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/environment.rb:178:in `initialize'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/bin/vagrant:145:in `new'
C:/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/bin/vagrant:145:in `<main>'
Vagrant failed to initialize at a very early stage:
There was an error loading a Vagrantfile. The file being loaded
and the error message are shown below. This is usually caused by
a syntax error.
Path: C:/cygwin64/home/user/xxx-dev/Vagrantfile
Line number: 0
Message: NoMethodError: undefined method `sub' for #<TeracyDev::Location::GitWarn:0x0000000004a6f528>

no error when $ cd ~/xxx-dev/workspace && vagrant status

hoatle commented 4 years ago
egor  11:21 AM
Thanks
11:21
It does work when I type it with env variables:
TERACY_DEV_ENTRY_LOCATION_GIT_REMOTE_ORIGIN=git@github.com:iorad/teracy-dev-entry.git \
    TERACY_DEV_ENTRY_LOCATION_GIT_BRANCH=master TERACY_DEV_ENTRY_LOCATION_SYNC=true \
    vagrant up
From this instruction: https://github.com/iorad/teracy-dev-entry/blob/master/README.md#setting-up-iorad-dev-from-scratch

hoatle  11:23 AM
I think it asked for your key passphrase or you already provided and it cached, we'll dig more on this, thank you for your information
hoatle commented 4 years ago

expected behavior: it should ask for passphase and continue syncing as normal