-
Notifications
You must be signed in to change notification settings - Fork 1
/
play_agents.yml
110 lines (93 loc) · 4.14 KB
/
play_agents.yml
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
---
- name: "Setup Aries Go Agents"
hosts: servers
become: yes
tasks:
- name: Install go
ansible.builtin.shell: |
mkdir /tmp/goinstall
cd /tmp/goinstall
curl -L -O https://golang.org/dl/go1.16.4.linux-amd64.tar.gz
tar xvf go1.16.4.linux-amd64.tar.gz
chown -R root:root ./go
mv go /usr/local
rm -rf /tmp/goinstall
args:
chdir: "/tmp/"
- name: Pull Hyperledger Aries repo
git:
repo: "https://github.com/hyperledger/aries-framework-go.git"
dest: "{{ agent_path }}"
version: "{{ agent_version }}"
force: yes
- name: Build aries agent
ansible.builtin.shell: |
PATH=$PATH:/usr/local/go/bin make agent-rest
ls ./build/bin/aries-agent-rest
args:
chdir: "{{ agent_path }}"
- name: Build mock webhook
ansible.builtin.shell: |
PATH=$PATH:/usr/local/go/bin make sample-webhook
ls ./build/bin/webhook-server
args:
chdir: "{{ agent_path }}"
##### STUDENT AGENT ######################################################
- name: "Setup Student Agent"
hosts: servers
become: yes
vars:
agent_context: "student"
agent_port: "{{ agent_student_port_inbound }}"
agent_env:
ARIESD_API_HOST: "localhost:{{ agent_student_port_api }}"
ARIESD_INBOUND_HOST: "http@localhost:{{ agent_student_port_inbound }}"
ARIESD_INBOUND_HOST_EXTERNAL: "http@https://{{ agent_student_domain }}"
ARIESD_WEBHOOK_URL: "https://enybebk8mydni.x.pipedream.net"
ARIESD_DEFAULT_LABEL: "{{ agent_context }}-agent"
ARIESD_DATABASE_TYPE: "leveldb"
ARIESD_DATABASE_PREFIX: "data/kraken-{{ agent_context }}"
ARIESD_DATABASE_TIMEOUT: "60"
#ARIESD_HTTP_RESOLVER: "web@https://resolver.prod.ari-bip.eu/1.0/identifiers,elem@https://resolver.prod.ari-bip.eu/1.0/identifiers,ebsi@https://resolver.prod.ari-bip.eu/1.0/identifiers"
ARIESD_HTTP_RESOLVER: "ebsi@https://api.preprod.ebsi.eu/did-registry/v2/identifiers,web@https://resolver.prod.ari-bip.eu/1.0/identifiers,elem@https://resolver.prod.ari-bip.eu/1.0/identifiers"
# TLS disabled at agent, since this is done by nginx
# TLS_CERT_FILE: "{{ agent_student_workdir }}/fullchain.pem"
# TLS_KEY_FILE: "{{ agent_student_workdir }}/privkey.pem"
ARIESD_CONTEXT_PROVIDER_URL: "https://context.prod.ari-bip.eu/agent-startup-contexts.json"
ARIESD_MEDIA_TYPE_PROFILES: "didcomm/aip2;env=rfc19"
ARIESD_KEY_TYPE: "ED25519"
ARIESD_KEY_AGREEMENT_TYPE: "X25519ECDHKW"
path_binary: "{{ agent_path_agent }}"
path_workdir: "{{ agent_student_workdir }}"
nginx_domain: "{{ agent_student_domain }}"
roles:
- role: aries_agent
##### UNIVERSITY AGENT ######################################################
- name: "Setup University Agent"
hosts: servers
become: yes
vars:
agent_context: "university"
agent_port: "{{ agent_university_port_inbound }}"
agent_env:
ARIESD_API_HOST: "localhost:{{ agent_university_port_api }}"
ARIESD_INBOUND_HOST: "http@localhost:{{ agent_university_port_inbound }}"
ARIESD_INBOUND_HOST_EXTERNAL: "http@https://{{ agent_university_domain }}"
ARIESD_WEBHOOK_URL: "https://enybebk8mydni.x.pipedream.net"
ARIESD_DEFAULT_LABEL: "{{ agent_context }}-agent"
ARIESD_DATABASE_TYPE: "leveldb"
ARIESD_DATABASE_PREFIX: "data/kraken-{{ agent_context }}"
ARIESD_DATABASE_TIMEOUT: "60"
ARIESD_HTTP_RESOLVER: "web@https://resolver.prod.ari-bip.eu/1.0/identifiers,elem@https://resolver.prod.ari-bip.eu/1.0/identifiers,ebsi@https://resolver.prod.ari-bip.eu/1.0/identifiers"
# TLS disabled at agent, since this is done by nginx
# TLS_CERT_FILE: "{{ agent_university_workdir }}/fullchain.pem"
# TLS_KEY_FILE: "{{ agent_university_workdir }}/privkey.pem"
ARIESD_CONTEXT_PROVIDER_URL: "https://context.prod.ari-bip.eu/agent-startup-contexts.json"
ARIESD_MEDIA_TYPE_PROFILES: "didcomm/aip2;env=rfc19"
ARIESD_KEY_TYPE: "ED25519"
ARIESD_KEY_AGREEMENT_TYPE: "X25519ECDHKW"
path_binary: "{{ agent_path_agent }}"
path_workdir: "{{ agent_university_workdir }}"
nginx_domain: "{{ agent_university_domain }}"
roles:
- role: aries_agent