summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjkito <jkito@github>2022-11-20 16:13:34 +0530
committerkali kaneko (leap communications) <kali@leap.se>2023-02-21 17:38:06 +0100
commita38a558b851eac14d862a01e2e72c36d5f2385f3 (patch)
treec5ccb503d5b49018e43c3ffd54f5bb76e77ec80b
parent164d847d9d54c0def39ab7151351a307dbc30c80 (diff)
[build] Add ansible playbook to setup build env on windows
-rw-r--r--scripts/ansible/windows/inventory.yaml9
-rw-r--r--scripts/ansible/windows/requirements.yaml4
-rw-r--r--scripts/ansible/windows/site.yaml51
3 files changed, 64 insertions, 0 deletions
diff --git a/scripts/ansible/windows/inventory.yaml b/scripts/ansible/windows/inventory.yaml
new file mode 100644
index 0000000..59819c9
--- /dev/null
+++ b/scripts/ansible/windows/inventory.yaml
@@ -0,0 +1,9 @@
+all:
+ hosts:
+ localhost:
+ ansible_host: 127.0.0.1
+ ansible_port: 22220
+ ansible_user: quickemu
+ ansible_connection: ssh
+ ansible_shell_type: powershell
+
diff --git a/scripts/ansible/windows/requirements.yaml b/scripts/ansible/windows/requirements.yaml
new file mode 100644
index 0000000..7804861
--- /dev/null
+++ b/scripts/ansible/windows/requirements.yaml
@@ -0,0 +1,4 @@
+---
+collections:
+ - name: ansible.windows
+ - name: chocolatey.chocolatey
diff --git a/scripts/ansible/windows/site.yaml b/scripts/ansible/windows/site.yaml
new file mode 100644
index 0000000..3089de1
--- /dev/null
+++ b/scripts/ansible/windows/site.yaml
@@ -0,0 +1,51 @@
+# vi: ft=yaml.ansible
+---
+- name: Setup go and Qt development environment in windows
+ hosts:
+ - all
+ tasks:
+ - name: Ensure Chocolatey itself is installed, using community repo for the
+ chocolatey.chocolatey.win_chocolatey:
+ name: chocolatey
+ state: present
+
+ - name: Install Golang 1.17
+ chocolatey.chocolatey.win_chocolatey:
+ name: golang
+ version: '1.17'
+ state: present
+
+ - name: Install Cygwin
+ chocolatey.chocolatey.win_chocolatey:
+ name: cygwin
+ state: present
+
+ - name: Install build dependencies and other tools
+ chocolatey.chocolatey.win_chocolatey:
+ name:
+ - qt5-default
+ - mingw
+ - sigcheck
+ - wget
+ - qt-installer-framework
+ - make
+ - git
+ - curl
+ - python3
+ - cyg-get
+ state: present
+
+ - name: Add cygwin, Qt and QtIFW binaries directories to PATH
+ ansible.windows.win_path:
+ state: present
+ elements:
+ - '%SystemDrive%\Qt\5.15.2\mingw81_64\bin'
+ - '%SystemDrive%\Qt\QtIFW-4.4.2\bin'
+ - '%SystemDrive%\tools\cygwin\bin'
+
+ - name: Install python3 for cygwin environment
+ ansible.windows.win_powershell:
+ creates: C:\tools\cygwin\bin\python3
+ script: |
+ cyg-get python3
+ ln -s $env:SystemDrive\tools\cygwin\bin\python $env:SystemDrive\tools\cygwin\bin\python3