-
Notifications
You must be signed in to change notification settings - Fork 0
/
Taskfile.yaml
46 lines (39 loc) · 1.24 KB
/
Taskfile.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
---
version: "3"
vars:
BOOTSTRAP_DIR: "{{.ROOT_DIR}}/bootstrap"
ANSIBLE_DIR: "{{.ROOT_DIR}}/ansible"
KUBERNETES_DIR: "{{.ROOT_DIR}}/kubernetes"
env:
KUBECONFIG: "{{.ROOT_DIR}}/kubeconfig"
SOPS_AGE_KEY_FILE: ~/.config/sops/age/keys.txt
includes:
ansible: .taskfiles/AnsibleTasks.yaml
brew: .taskfiles/BrewTasks.yaml
cluster: .taskfiles/ClusterTasks.yaml
precommit: .taskfiles/PrecommitTasks.yml
tasks:
default: task -l
init:
desc: Initialize configuration files
dir: "{{.BOOTSTRAP_DIR}}"
cmds:
- cp -n vars/addons.sample.yaml vars/addons.yaml
- cp -n vars/config.sample.yaml vars/config.yaml
- cmd: echo "=== Configuration files copied ==="
silent: true
- cmd: echo "Proceed with updating the configuration files..."
silent: true
- cmd: echo "{{.BOOTSTRAP_DIR}}/vars/config.yaml"
silent: true
- cmd: echo "{{.BOOTSTRAP_DIR}}/vars/addons.yaml"
silent: true
status:
- test -f "{{.BOOTSTRAP_DIR}}/vars/addons.yaml"
- test -f "{{.BOOTSTRAP_DIR}}/vars/config.yaml"
configure:
desc: Configure repository from Ansible vars
dir: "{{.BOOTSTRAP_DIR}}"
cmd: ansible-playbook configure.yaml
env:
ANSIBLE_DISPLAY_SKIPPED_HOSTS: "false"