Closed tkang007 closed 4 years ago
hi @tkang007,
Thank you for reporting this issue and I'm sorry to hear that this is broken for you. I'm wondering if you can help me out by providing your vagrant file that you are using? I ask, so that I can try and replicate this issue on my side.
I have assessed the code and I believe I see what the problem is, but since I don't have a windows machine it's hard for me to confirm that this will work on Windows. I suspect and it's total speculation at this point but I suspect there is a permissisions issue when the temporary file is uploaded to your guest and this logic https://github.com/tmatilai/vagrant-proxyconf/blob/master/lib/vagrant-proxyconf/action/configure_docker_proxy.rb#L146-L155 is failing silently. I'll do some more local testing but I'd love to see your vagrantfile as well.
Hope to hear from you soon and thanks again for reporting.
I've added a "touch" statement and it's currently running through some local testing. Once complete, I'll push this in the next day or so.
Just a friendly heads up, I've prepped this release and it's currently staged in master. I'll cut the release to rubygems and tag the release by the end of the week. Release info will updated in issue #211
Thanks again for reporting, addressed this issue via the attached commits.
Closing out this issue.
Hi, When install docker, the vagrant up could be failed as below as the docker proxy conf file was not exist. When crated the file, it will succeed. Please check the file existence before doing chmod.
c:\mywork\vagrant\centos76b λ vagrant plugin update vagrant-proxyconf Updating plugins: vagrant-proxyconf. This may take a few minutes... Fetching: vagrant-proxyconf-2.0.6.gem (100%) Successfully uninstalled vagrant-proxyconf-2.0.5 Updated 'vagrant-proxyconf' to version '2.0.6'!
c:\mywork\vagrant\centos76b λ vagrant halt ==> default: Attempting graceful shutdown of VM...
c:\mywork\vagrant\centos76b λ vagrant up Bringing machine 'default' up with 'virtualbox' provider... ==> default: Checking if box 'centos/7' version '1905.1' is up to date... ==> default: Clearing any previously set forwarded ports... ==> default: Clearing any previously set network interfaces... ==> default: Preparing network interfaces based on configuration... default: Adapter 1: nat ==> default: You are trying to forward to privileged ports (ports <= 1024). Most ==> default: operating systems restrict this to only privileged process (typically ==> default: processes running as an administrative user). This is a warning in case ==> default: the port forwarding doesn't work. If any problems occur, please try a ==> default: port higher than 1024. ==> default: Forwarding ports... ... default: 5000 (guest) => 5000 (host) (adapter 1) ==> default: Running 'pre-boot' VM customizations... ==> default: Booting VM... ==> default: Waiting for machine to boot. This may take a few minutes... default: SSH address: 127.0.0.1:22 default: SSH username: vagrant default: SSH auth method: private key default: Warning: Connection reset. Retrying... ==> default: Machine booted and ready! ==> default: Configuring proxy for Docker... The following SSH command responded with a non-zero exit status. Vagrant assumes that this means the command failed!
chmod 0644 /etc/systemd/system/docker.service.d/http-proxy.conf
Stdout from the command:
Stderr from the command:
chmod: cannot access ‘/etc/systemd/system/docker.service.d/http-proxy.conf’: No such file or directory
c:\mywork\vagrant\centos76b λ /etc/systemd/system/docker.service.d/http-proxy.conf c:\mywork\vagrant\centos76b λ vagrant ssh Last login: Mon Sep 23 16:25:02 2019 from 10.0.2.2 [vagrant@centos76b ~]$ sudo -i -bash-4.2# touch /etc/systemd/system/docker.service.d/http-proxy.conf