Skip to content
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

Windows specific installation instruction #100

Open
luboskmetko opened this issue May 30, 2018 · 11 comments

Comments

Projects
None yet
6 participants
@luboskmetko
Copy link
Collaborator

commented May 30, 2018

Eventually, I've made tide.local API work on Windows 10 Home Edition (thanks @valendesigns for help and ideas)

The following is a list of Windows specific issues we should address in documentation.

First of all, Windows Home doesn't support Hyper-V so you have to use legacy Docker Toolbox. On Windows 10 Pro some of these might not be an issue.

  • clone Tide repo into C:\Users\[YourName]\go\src\github.com\wptide\wptide to avoid problems with properly mounting shared volumes and to be able to build servers
  • make command is not available on Windows by default. Make for Windows should be enough to be able to use Tide make commands. Install and add C:\zlib\bin to PATH
  • Docker on Windows is configured to use the default machine with a specific IP like 192.168.99.100. So on Windows you need to add 192.168.99.100 tide.local to the hosts file instead of 127.0.0.1 localhost. Changing webserver/MySQL ports then shouldn't be necessary.
@jeffpaul

This comment has been minimized.

Copy link
Member

commented Aug 29, 2018

Per bugscrub today, we're keeping this in the 1.0.0 release. This will need some testing, but will aim for some basic docs as noted in the issue description from @luboskmetko.

@carolinan

This comment has been minimized.

Copy link

commented Oct 19, 2018

Zlib, as referenced above and in the prerequisites in the documentation, is a different package than Make. Since I am having problems with the install, I am not 100% clear here; is this a form of typo, or do I perhaps need to install both Make and Zlib?
My installation of Make is in a different directory, C:\Program Files (x86)\GnuWin32\bin and this is the directory I have added to my PATH.

In the documentation, the first step of Setup, it says
$ cp .env.dist .env, on Windows cp needs to be replaced with 'copy' .

And for someone who has never used Tide, this part of the documentation is very confusing:
For local development you have to manually set the API_KEY and API_SECRET for the audit-server user, which will automatically update the user meta values when make api.setup is ran. If you are running Tide in production, then you can access the auto generated key and secret from the audit-server user profile.
It is even more confusing when you open the .env file and there are a lot of lines ending with
"<CHANGE_THIS_VALUE>"

Anyway the real problem begins when I try make api.composer and I see the following error:

process_begin: CreateProcess(NULL, bash C:\Users\Carolina\go\src\github.com\wptide\bin\tpl -t=service/api/tpl/app.tpl -d=service/api/app.yaml -e=.env.gcp, ...) failed.
make (e=2): File not found
make: *** [api.tpl] Error 2

I have not been able to narrow it down to which file is missing, but the destination files
listed in the Make file are not being created.

# Generate the API templates.
api.tpl:
	@./bin/tpl -t=service/api/tpl/app.tpl -d=service/api/app.yaml -e=.env.gcp
	@./bin/tpl -t=service/api/tpl/cron.tpl -d=service/api/cron.yaml -e=.env.gcp
	@./bin/tpl -t=service/api/tpl/wp-config.tpl -d=service/api/wp-config.php -e=.env.gcp

I have tried both the xwp version in the documentation, and the wptide develop branch as suggested,
(git clone -b develop --recursive https://github.com/wptide/wptide.git)

I have confirmed that composer, go, glide, and make works.
Windows 10 pro,
Hyper V is enabled.
Docker version Version 18.06.1-ce-win73 (19507)
Composer version 1.7.2 2018-08-16 16:57:12
Glide version 0.13.2-dev

Go, composer, make, glide are all in the PATH, together with a bunch of other stuff like the wptide directory, php, git etc.

@jeffpaul

This comment has been minimized.

Copy link
Member

commented Oct 22, 2018

Thanks for the details @carolinan, I'm working through some doc updates and will work to get answers to the issues you've pointed out.

@ronakganatra9

This comment has been minimized.

Copy link

commented Oct 25, 2018

I am getting this error while make api.up

$ make api.up
Pulling api-mysql (mariadb:10.3)...
10.3: Pulling from library/mariadb
no matching manifest for unknown in the manifest list entries
make: *** [api.up] Error 1

Does any one has any suggestion ?

@ronakganatra9

This comment has been minimized.

Copy link

commented Oct 26, 2018

Zlib, as referenced above and in the prerequisites in the documentation, is a different package than Make. Since I am having problems with the install, I am not 100% clear here; is this a form of typo, or do I perhaps need to install both Make and Zlib?
My installation of Make is in a different directory, C:\Program Files (x86)\GnuWin32\bin and this is the directory I have added to my PATH.

In the documentation, the first step of Setup, it says
$ cp .env.dist .env, on Windows cp needs to be replaced with 'copy' .

And for someone who has never used Tide, this part of the documentation is very confusing:
For local development you have to manually set the API_KEY and API_SECRET for the audit-server user, which will automatically update the user meta values when make api.setup is ran. If you are running Tide in production, then you can access the auto generated key and secret from the audit-server user profile.
It is even more confusing when you open the .env file and there are a lot of lines ending with
"<CHANGE_THIS_VALUE>"

Anyway the real problem begins when I try make api.composer and I see the following error:

process_begin: CreateProcess(NULL, bash C:\Users\Carolina\go\src\github.com\wptide\bin\tpl -t=service/api/tpl/app.tpl -d=service/api/app.yaml -e=.env.gcp, ...) failed.
make (e=2): File not found
make: *** [api.tpl] Error 2

I have not been able to narrow it down to which file is missing, but the destination files
listed in the Make file are not being created.

# Generate the API templates.
api.tpl:
	@./bin/tpl -t=service/api/tpl/app.tpl -d=service/api/app.yaml -e=.env.gcp
	@./bin/tpl -t=service/api/tpl/cron.tpl -d=service/api/cron.yaml -e=.env.gcp
	@./bin/tpl -t=service/api/tpl/wp-config.tpl -d=service/api/wp-config.php -e=.env.gcp

I have tried both the xwp version in the documentation, and the wptide develop branch as suggested,
(git clone -b develop --recursive https://github.com/wptide/wptide.git)

I have confirmed that composer, go, glide, and make works.
Windows 10 pro,
Hyper V is enabled.
Docker version Version 18.06.1-ce-win73 (19507)
Composer version 1.7.2 2018-08-16 16:57:12
Glide version 0.13.2-dev

Go, composer, make, glide are all in the PATH, together with a bunch of other stuff like the wptide directory, php, git etc.

Same issue is coming to me also.

@nikola3244

This comment has been minimized.

Copy link

commented Oct 26, 2018

@carolinan and others who experience that error, this might help:

  1. Right click Docker instance*
  2. Go to Settings
  3. Daemon
  4. Advanced
  5. Set the "experimental": true
  6. Restart Docker

* Docker Instance is the Docker icon in Windows' task bar

(source)


@ronakganatra9 confirmed on Slack that it resolves the issue on his end

@ronakganatra9

This comment has been minimized.

Copy link

commented Oct 27, 2018

Yes, @nikola3244 ,

Thanks. It worked for me and my error got fixed.

but after completing the process I received the following error.

Can anyone check it and guide me if I am doing anything wrong.

$ make api.up
Creating go-tide_mongo_1 ...
Creating go-tide_api-redis_1 ... error
Creating go-tide_api-mysql_1 ...

ERROR: for go-tide_api-redis_1 Cannot create container for service api-redis: invalid volume specification: 'C:\Users\MD185-RonakG\go\src\github.com\xwp\go-tidCreating go-tide_mongo_1 ... error
rce path does not exist: c:\users\md185-ronakg\go\src\github.com\xwp\go-tide\data\api\redis

ERROR: for go-tide_mongo_1 Cannot create container for service mongo: invalid volume specification: 'C:\Users\MD185-RonakG\go\src\github.com\xwp\go-tide\data\mCreating go-tide_api-mysql_1 ... error

ERROR: for go-tide_api-mysql_1 Cannot create container for service api-mysql: invalid volume specification: 'C:\Users\MD185-RonakG\go\src\github.com\xwp\go-tide\service\api\wptests.sql:/docker-entrypoint-initdb.d/wptests.sql:rw': invalid mount config for type "bind": source path must be a directory

ERROR: for api-redis Cannot create container for service api-redis: invalid volume specification: 'C:\Users\MD185-RonakG\go\src\github.com\xwp\go-tide\data\api\redis:/data:rw': invalid mount config for type "bind": bind mount source path does not exist: c:\users\md185-ronakg\go\src\github.com\xwp\go-tide\data\api\redis

ERROR: for mongo Cannot create container for service mongo: invalid volume specification: 'C:\Users\MD185-RonakG\go\src\github.com\xwp\go-tide\data\mongo:/data/db:rw'

ERROR: for api-mysql Cannot create container for service api-mysql: invalid volume specification: 'C:\Users\MD185-RonakG\go\src\github.com\xwp\go-tide\service\api\wptests.sql:/docker-entrypoint-initdb.d/wptests.sql:rw': invalid mount config for type "bind": source path must be a directory
Encountered errors while bringing up the project.
make: *** [api.up] Error 1

It would be great if anyone can help me on this.

@carolinan

This comment has been minimized.

Copy link

commented Oct 27, 2018

I am still getting the same error about the file not being found.

@jeffpaul jeffpaul added this to the 1.0.0-beta2 milestone Nov 26, 2018

@jeffpaul

This comment has been minimized.

Copy link
Member

commented Nov 28, 2018

Note that this issue was referenced in Slack.

@valendesigns

This comment has been minimized.

Copy link
Member

commented Feb 27, 2019

This seems related to this issue in OS X...

  1. If you see the following error in your OS X terminal when bringing up the API you need to add the /Users directory to the Preferences -> File Sharing section of the Docker for Mac app, or whatever the root directory is for you $GOPATH.
ERROR: for wptide_api-mysql_1  Cannot start service api-mysql: b'Mounts denied: ...'
  1. The other possibility is that the container doesn't have permission to create directories inside the data directory in the project root. One way to solve this is to manually create all the missing directories.

missing-directories

You should also pull changes incase your branch is out of date. .kitkeep files were added at some point so they should automatically be added now.

If it's not either of these things I'm out of ideas.

@jeffpaul jeffpaul pinned this issue Jun 5, 2019

@jeffpaul jeffpaul modified the milestones: 1.0.0, Future Release Jul 16, 2019

@jeffpaul

This comment has been minimized.

Copy link
Member

commented Jul 16, 2019

Moving to Future Release as there hasn't been progress on testing this and providing feedback / updating docs for Windows users. For 1.0.0 we'll focus support on *nix systems and look to better support Windows when feasible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.