author | Mahlon E. Smith <mahlon@martini.nu> |
Wed, 31 Oct 2018 13:22:13 -0700 | |
changeset 378 | a788cfad4cfa |
parent 349 | b271be84da5e |
permissions | -rw-r--r-- |
348
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
1 |
Windows setup for mercurial-server |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
2 |
================================== |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
3 |
|
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
4 |
WARNING: Windows is *not* a supported system. We've gotten this guide to work ok |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
5 |
but the permissions are still broken in various ways to do with the underlying |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
6 |
issues in Windows' permissions system. Unix-based systems, especially Debian and |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
7 |
derivatives are still the main target. Patches to this guide to improve the |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
8 |
support are welcome however! |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
9 |
|
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
10 |
1) Install Cygwin (http://cygwin.com/) using the setup.exe from there. Tested |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
11 |
against 1.7.12-1, may work with earlier versions. You'll need the base install |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
12 |
plus the following additional packages: |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
13 |
|
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
14 |
- docbook-xsl |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
15 |
- libxslt |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
16 |
- make |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
17 |
- mercurial |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
18 |
- openssh |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
19 |
- python |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
20 |
|
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
21 |
Note that even if you've already got them installed in Windows, Python and |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
22 |
Mercurial still need to be installed in Cygwin. |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
23 |
|
349
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
24 |
2) Open a new Cygwin terminal as Adminstrator (under Windows 7, that's right |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
25 |
click on "Cygwin Terminal" start menu option and pick "Run as administrator") |
347
301479a4acdf
Initial notes and work towards a Windows install
Tom Parker<palfrey@lshift.net>
parents:
diff
changeset
|
26 |
|
348
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
27 |
3) Run "ssh-host-config -y" and "cygrunsrv -S sshd" to get sshd running. We need |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
28 |
this because there's no proper su in Cygwin (see |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
29 |
http://cygwin.com/faq-nochunks.html#faq.using.su for why this is) |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
30 |
|
349
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
31 |
3) Goto the mercurial-server folder and "sh windows.sh setup-windows" |
348
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
32 |
|
349
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
33 |
4) Run "passwd hg" and set the password for the hg user (created by |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
34 |
setup-windows), then "mkpasswd -l > /etc/passwd" to add them to the Cygwin user |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
35 |
database |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
36 |
|
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
37 |
5) Run "sh windows.sh inituser-windows" to finish setting up the hg user |
348
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
38 |
|
349
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
39 |
5) Following the example from the main mercurial-server documentation (in that |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
40 |
the server is called 'jeeves', your username is 'jay' and the client is called |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
41 |
'spoon'), but with a few differences for Cygwin, we can now get you initial |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
42 |
access. We assume that you've generated a key with PuTTYgen |
348
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
43 |
(http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html) and then |
349
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
44 |
copied the contents of the "public key" box into a file called my-key. Run the |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
45 |
following, altered as appropriate for your local system: |
348
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
46 |
|
349
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
47 |
mkdir -p /etc/mercurial-server/keys/root/jay |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
48 |
cp my-key /etc/mercurial-server/keys/root/jay/spoon |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
49 |
chown hg /etc/mercurial-server/keys/root/jay/spoon |
b271be84da5e
Fix windows issues that cropped up in the new install
Tom Parker <palfrey@lshift.net>
parents:
348
diff
changeset
|
50 |
ssh hg@localhost /usr/local/share/mercurial-server/refresh-auth |
348
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
51 |
|
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
52 |
The rest of the instructions in the normal mercurial-server documentation should |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
53 |
now work. Note that although it's possible to add keys/access info to |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
54 |
/etc/mercurial-server it's much easier to do things via the hgadmin repository, |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
55 |
and doing things via /etc should probably be limited to only if you mess up the |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
56 |
setup in hgadmin. |
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
57 |
|
b155c43eaa56
Update windows guide and fix a couple of minor items in the Makefile
Tom Parker <palfrey@lshift.net>
parents:
347
diff
changeset
|
58 |
# vim: tw=80 fo=cqt wm=0 |