10000 Virtual development environment by kasparsd · Pull Request #123 · wptide/wptide · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Virtual development environment #123

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 14 commits into
base: develop
Choose a base branch
from

Conversation

kasparsd
Copy link

Work in progress!

Add support for running the project in a virtual environment to simplify the local development on all types of operating systems as users no longer have to install the project dependancies on their host machine.

Description of the Change

  • Introduce Vagrantfile at the project root which defines the virtual environment.
  • Introduce bin/vagrant-provision.sh and bin/vagrant-up.sh scripts which provision the virtual environment and start the Docker containers inside the virtual environment.

Verification Process

  • Install VirtualBox and Vagrant.
  • Run vagrant up to provision the environment.
  • Visit http://tide.local

Applicable Issues

https://github.com/wptide/tide-local/issues/9

@coveralls
Copy link
coveralls commented Jun 12, 2018

Pull Request Test Coverage Report for Build 527

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 16 unchanged lines in 1 file lost coverage.
  • Overall coverage increased (+0.1%) to 98.414%

Files with Coverage Reduction New Missed Lines %
cmd/lighthouse-server/main.go 16 93.19%
Totals Coverage Status
Change from base Build 526: 0.1%
Covered Lines: 993
Relevant Lines: 1009

💛 - Coveralls

@@ -66,6 +66,10 @@ build.up: build.images up
up:
@docker-compose up

# Start the Docker daemon with docker-compose up.
upd:
@docker-compose -d up
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We want to leave these running in the background so we need to start them as daemons.

cd /vagrant

# Build all service Docker images and Go binaries.
make build.images
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is currently failing with the following error:

$ make build.images
Installing dependencies ...
[WARN]	The name listed in the config file (github.com/xwp/go-tide) does not match the current location (.)
[INFO]	Downloading dependencies. Please wait...
[INFO]	--> Found desired version locally cloud.google.com/go 0fd7230b2a7505833d5f69b75cbd6c9582401479!
...
[INFO]	--> Setting version for gopkg.in/toqueteos/substring.v1 to c5f61671513240ddf5563635cc4a90e9f3ae4710.
[INFO]	--> Setting version for cloud.google.com/go to 0fd7230b2a7505833d5f69b75cbd6c9582401479.
[INFO]	Exporting resolved dependencies...
[INFO]	--> Exporting github.com/aws/aws-sdk-go
[INFO]	--> Exporting github.com/toqueteos/trie
...
[INFO]	Replacing existing vendor dependencies
Cleaning up Lighthouse Server GO binary 'bin/lighthouse-server' ...
Cleaning up PHPCS Server GO binary 'bin/phpcs-server' ...
Cleaning up Sync Server GO binary 'bin/sync-server' ...
Building Lighthouse Server GO binary 'bin/lighthouse-server' ...
cmd/lighthouse-server/main.go:19:2: cannot find package "context" in any of:
	/usr/lib/go-1.6/src/context (from $GOROOT)
	/home/vagrant/go/src/context (from $GOPATH)
cmd/lighthouse-server/main.go:10:2: cannot find package "github.com/wptide/pkg/env" in any of:
	/usr/lib/go-1.6/src/github.com/wptide/pkg/env (from $GOROOT)
	/home/vagrant/go/src/github.com/wptide/pkg/env (from $GOPATH)
...
service/lighthouse-server/Makefile:29: recipe for target 'lighthouse.build.bin' failed
make: *** [lighthouse.build.bin] Error 1

@rheinardkorf Do you have ideas on why that is happening? It appears to be looking at /home/vagrant/go/src and /usr/lib/go-1.6/src for dependancies while they're actually stored at /vagrant/vendor.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0