-
Notifications
You must be signed in to change notification settings - Fork 341
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Aggregator ansible #1387
Draft
samoht9277
wants to merge
9
commits into
1344-ci-improve-servers-setup
Choose a base branch
from
aggregator_ansible
base: 1344-ci-improve-servers-setup
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Aggregator ansible #1387
Changes from 3 commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
dbdd119
ci: aggregator ansible.
samoht9277 c4f3a0f
Merge branch '1344-ci-improve-servers-setup' into aggregator_ansible
samoht9277 1fcbd67
added newline to batcher file.
samoht9277 f1febe3
nit
JuArce 8bb62d0
Added config files for template.
samoht9277 572e5e7
Added config files for template.
samoht9277 25bb0ec
Removed gcc.
samoht9277 ee54e95
Removed newline.
samoht9277 65c88fd
Added ini and templates for aggregator, still needs documentation.
samoht9277 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
- name: Run setup playbook | ||
ansible.builtin.import_playbook: setup.yaml | ||
vars: | ||
host: aggregator | ||
|
||
- name: Run go playbook | ||
ansible.builtin.import_playbook: go.yaml | ||
vars: | ||
host: aggregator | ||
|
||
- name: Run rust playbook | ||
ansible.builtin.import_playbook: rust.yaml | ||
vars: | ||
host: aggregator | ||
|
||
- name: Run eigenlayer-cli playbook | ||
ansible.builtin.import_playbook: eigenlayer-cli.yaml | ||
vars: | ||
host: aggregator | ||
|
||
- hosts: aggregator | ||
vars: | ||
service: "aggregator" | ||
|
||
tasks: | ||
- name: Update apt and install required system packages | ||
become: true | ||
apt: | ||
pkg: | ||
- pkg-config | ||
- libssl-dev | ||
- gcc | ||
state: latest | ||
update_cache: true | ||
vars: | ||
ansible_ssh_user: "{{ admin_user }}" | ||
|
||
- name: Create directories for each service if do not exist | ||
file: | ||
path: /home/{{ ansible_user }}/repos/{{ service }} | ||
state: directory | ||
mode: '0755' | ||
owner: '{{ ansible_user }}' | ||
group: '{{ ansible_user }}' | ||
loop: | ||
- aggregator | ||
|
||
- name: Clone Aligned repository | ||
git: | ||
repo: https://github.com/yetanotherco/aligned_layer.git | ||
dest: /home/{{ ansible_user }}/repos/{{ service }}/aligned_layer | ||
version: v0.10.2 | ||
loop: | ||
- aggregator | ||
|
||
- name: Set permissions for cloned repository | ||
file: | ||
path: /home/{{ ansible_user }}/repos/{{ service }}/aligned_layer | ||
mode: '0755' | ||
owner: '{{ ansible_user }}' | ||
group: '{{ ansible_user }}' | ||
recurse: yes | ||
|
||
- name: Compile all FFIs | ||
make: | ||
chdir: /home/{{ ansible_user }}/repos/aggregator/aligned_layer | ||
target: build_all_ffi_linux | ||
environment: | ||
PATH: "{{ ansible_env.PATH }}:/usr/local/go/bin:/home/{{ ansible_user }}/.cargo/bin" | ||
|
||
- name: Allow access to tcp port 8090 | ||
become: true | ||
ufw: | ||
rule: allow | ||
port: 8090 | ||
proto: tcp | ||
vars: | ||
ansible_ssh_user: "{{ admin_user }}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gcc is already in setup
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it. Removing now.