-
Notifications
You must be signed in to change notification settings - Fork 3
/
ovh_builder.yml
90 lines (75 loc) · 1.97 KB
/
ovh_builder.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
---
- hosts: localhost
tasks:
- name: OVH create instance
include_tasks: ovh_instance_create.yml
with_items: "{{ ovh_instances }}"
- hosts: ovh_instances
gather_facts: no
tasks:
- name: Wait for connection
wait_for_connection:
delay: 10
timeout: 300
- hosts: ovh_instances
become: yes
roles:
- geerlingguy.docker
- mambaorg.micromamba
vars:
dest: "{{ mamba_exe }}"
- hosts: ovh_instances
roles:
- mambaorg.micromamba
vars:
dest: "{{ mamba_exe }}"
root_prefix: "{{ mamba_root_prefix }}"
root_prefix_condarc:
channels:
- conda-forge
packages:
- python
- gh
- awscli
- hosts: ovh_instances
tasks:
- name: Add Ansible user to docker group
become: yes
user:
name: "{{ansible_user}}"
groups: docker
- name: Update .bashrc
template:
src: templates/bashrc.j2
dest: ~/.bashrc
- name: Reload Bash configuration
meta: reset_connection
- name: Copy feedstock_checkout
template:
src: templates/feedstock_checkout.j2
dest: ~/feedstock_checkout.sh
mode: u=rwx,g=rx,o=rx
- name: Copy feedstock_build
template:
src: templates/feedstock_build.j2
dest: ~/feedstock_build.sh
mode: u=rwx,g=rx,o=rx
- name: Run feedstock_checkout
shell: ~/feedstock_checkout.sh
environment:
GH_TOKEN: "{{ gh_token }}"
GH_REPO: "{{ gh_repo }}"
GH_PR: "{{ gh_pr}}"
vars:
gh_repo: "conda-forge/tensorflow-feedstock"
gh_pr: ""
- name: Run feedstock_build
shell: tmux new-session -d -s builder "/bin/bash -l -i ~/feedstock_build.sh"
environment:
VARIANT: "{{ build_variant }}"
AWS_ACCESS_KEY_ID: "{{ aws_key_id }}"
AWS_SECRET_ACCESS_KEY: "{{ aws_secret_key }}"
AWS_DEFAULT_REGION: "{{aws_default_region}}"
vars:
build_variant: linux_64_cuda_compiler_version11.2cudnn8python3.9.____cpython
aws_default_region: "eu-central-1"