Configuration Common Windows: Difference between revisions
Jump to navigation
Jump to search
(Created page with "== MSYS2 on corporate PC == * Use installer <code>msys2-x86_64-20240507.ex</code>. :* '''Issue''' Install is stuck at 50% (see [https://github.com/msys2/MSYS2-packages/issues/2580 Issue #2580]). :* Looking in task manager with see a <code>bash</code> process, running <code>/usr/bin/pacman-key --refresh-keys</code>. :* We kill the process and let the install proceed. * Setup the corporate proxy, see Proxy. * Tell pacman to use our corporate certificates. :* Collect co...") |
|||
Line 4: | Line 4: | ||
:* Looking in task manager with see a <code>bash</code> process, running <code>/usr/bin/pacman-key --refresh-keys</code>. |
:* Looking in task manager with see a <code>bash</code> process, running <code>/usr/bin/pacman-key --refresh-keys</code>. |
||
:* We kill the process and let the install proceed. |
:* We kill the process and let the install proceed. |
||
* Setup |
* Setup <code>http_proxy</code> variables in {{file|.bashrc}}, see [[Proxy]]. |
||
* Tell pacman to use our corporate certificates. |
* Tell pacman to use our corporate certificates. |
||
:* Collect corporate root certificate by visiting one of the msys2 repository (https://repo.msys2.org) (see [https://stackoverflow.com/questions/69348953/certificate-error-when-trying-to-install-msys2-packages-on-windows-server/70398349#70398349 SO for chrome]). |
:* Collect corporate root certificate by visiting one of the msys2 repository (https://repo.msys2.org) (see [https://stackoverflow.com/questions/69348953/certificate-error-when-trying-to-install-msys2-packages-on-windows-server/70398349#70398349 SO for chrome]). |
||
Line 20: | Line 20: | ||
* Download, build and install connect-proxy (https://github.com/larryhou/connect-proxy.git, commit 63a650a) |
* Download, build and install connect-proxy (https://github.com/larryhou/connect-proxy.git, commit 63a650a) |
||
* Install Git For Windows. |
* Install Git For Windows. |
||
* Setup <code>http_proxy</code> variables in {{file|.bashrc}}, see [[Proxy]]. |
|||
* Setup auto ssh forward for IMAP: |
* Setup auto ssh forward for IMAP: |
||
:* This assumes that the SSH key shares the same password as the proxy |
:* This assumes that the SSH key shares the same password as the proxy |
Revision as of 14:44, 9 July 2024
MSYS2 on corporate PC
- Use installer
msys2-x86_64-20240507.ex
.
- Issue Install is stuck at 50% (see Issue #2580).
- Looking in task manager with see a
bash
process, running/usr/bin/pacman-key --refresh-keys
. - We kill the process and let the install proceed.
- Setup
http_proxy
variables in .bashrc, see Proxy. - Tell pacman to use our corporate certificates.
- Collect corporate root certificate by visiting one of the msys2 repository (https://repo.msys2.org) (see SO for chrome).
- Append corporate ROOT and intermediate SSL certificates (in Base64 format, see SSL) into etc/ssl/certs/ca-bundle.crt.
- Edit /etc/pacman.conf, here using
curl
:
XferCommand = /usr/bin/curl --cacert /etc/ssl/certs/ca-bundle.crt -L -C - -f -o %o %u
- Alternatively use option
--ca-directory=/usr/ssl/certs
withwget
.
- Alternatively use option
- Install a few packages:
pacman -S openssh openssl vim base base-devel gcc procps
- Download, build and install autossh (autossh-1.4e.tgz).
- Download, build and install connect-proxy (https://github.com/larryhou/connect-proxy.git, commit 63a650a)
- Install Git For Windows.
- Setup auto ssh forward for IMAP:
- This assumes that the SSH key shares the same password as the proxy
- File bin/echo-proxy-pass:
#!/bin/bash
echo "$HTTP_PROXY_PASSWORD"
unset HTTP_PROXY_PASSWORD
- File bin/startup.sh:
# Add our ssh keys - eval because ssh-add.list contains '~'
DISPLAY="0:0" SSH_ASKPASS="echo-proxy-pass" SSH_ASKPASS_REQUIRE=force ssh-add ~/.ssh/id_ed25519_winmail < /dev/null
pgrep -x autossh > /dev/null || autossh -M 0 -f -N -n -q -L 9143:localhost:9143 -L 9025:localhost:9025 ovhi
# Check that ssh is running fine (must keep same PID)
ps faux|grep "bin/ssh$" && sleep 2 && ps faux|grep "bin/ssh$"