# packages are defined in the pkg manager
# specific var files.
packages: []
+
+# the user teuthology will use
+teuthology_user: "ubuntu"
# configure pip to use our mirror
- include: pip.yml
-- name: Set a high max open files limit
+- name: Set a high max open files limit for the teuthology user.
template:
src: security_limits.conf
- dest: /etc/security/limits.d/ubuntu.conf
+ dest: "/etc/security/limits.d/{{ teuthology_user }}.conf"
owner: root
group: root
mode: 0755
---
-- name: Create /home/ubuntu/.pip
+- name: Create the .pip directory for the teuthology user.
file:
- path: /home/ubuntu/.pip
- owner: ubuntu
- group: ubuntu
+ path: "/home/{{ teuthology_user }}/.pip"
+ owner: "{{ teuthology_user }}"
+ group: "{{ teuthology_user }}"
mode: 0644
state: directory
- name: Create pip.conf and configure it to use our mirror
template:
src: pip.conf
- dest: /home/ubuntu/.pip/pip.conf
- owner: ubuntu
- group: ubuntu
+ dest: "/home/{{ teuthology_user }}/.pip/pip.conf"
+ owner: "{{ teuthology_user }}"
+ group: "{{ teuthology_user }}"
mode: 0644
name: "{{ new_hostname.stdout }}"
when: existing_hostname.stdout.find("{{ lab_domain | mandatory }}") != -1
-- name: Add ubuntu CPAN config directory.
+- name: Add CPAN config directory for the teuthology user.
file:
- path: /home/ubuntu/.cpan/CPAN/
- owner: ubuntu
- group: ubuntu
+ path: "/home/{{ teuthology_user }}/.cpan/CPAN/"
+ owner: "{{ teuthology_user }}"
+ group: "{{ teuthology_user }}"
mode: 0755
recurse: yes
state: directory
-- name: Add root CPAN config directory.
+- name: Add CPAN config directory for the root user.
file:
path: /root/.cpan/CPAN/
owner: root
recurse: yes
state: directory
-- name: Upload CPAN config for ubuntu.
+- name: Upload CPAN config for the teuthology user.
template:
src: ../../templates/cpan_config.pm
- dest: /home/ubuntu/.cpan/CPAN/MyConfig.pm
- owner: ubuntu
- group: ubuntu
+ dest: "/home/{{ teuthology_user }}/.cpan/CPAN/MyConfig.pm"
+ owner: "{{ teuthology_user }}"
+ group: "{{ teuthology_user }}"
mode: 0755
- name: Upload CPAN config for root.
path: /etc/fuse.conf
mode: 0644
-- name: Add user ubuntu to group kvm
+- name: Add the teuthology user to group kvm
user:
- name: ubuntu
+ name: "{{ teuthology_user }}"
group: kvm
- name: Upload rhel version specific sshd_config.
'applypatch' => q[],
'auto_commit' => q[0],
'build_cache' => q[100],
- 'build_dir' => q[/home/ubuntu/.cpan/build],
+ 'build_dir' => q[/home/{{ teuthology_user }}/.cpan/build],
'build_dir_reuse' => q[0],
'build_requires_install_policy' => q[yes],
'bzip2' => q[/bin/bzip2],
'colorize_output' => q[0],
'commandnumber_in_prompt' => q[1],
'connect_to_internet_ok' => q[1],
- 'cpan_home' => q[/home/ubuntu/.cpan],
+ 'cpan_home' => q[/home/{{ teuthology_user }}/.cpan],
'ftp_passive' => q[1],
'ftp_proxy' => q[],
'getcwd' => q[cwd],
'gpg' => q[/usr/bin/gpg],
'gzip' => q[/bin/gzip],
'halt_on_failure' => q[0],
- 'histfile' => q[/home/ubuntu/.cpan/histfile],
+ 'histfile' => q[/home/{{ teuthology_user }}/.cpan/histfile],
'histsize' => q[100],
'http_proxy' => q[],
'inactivity_timeout' => q[0],
'index_expire' => q[1],
'inhibit_startup_message' => q[0],
- 'keep_source_where' => q[/home/ubuntu/.cpan/sources],
+ 'keep_source_where' => q[/home/{{ teuthology_user }}/.cpan/sources],
'load_module_verbosity' => q[none],
'make' => q[/usr/bin/make],
'make_arg' => q[],
'perl5lib_verbosity' => q[none],
'prefer_external_tar' => q[1],
'prefer_installer' => q[MB],
- 'prefs_dir' => q[/home/ubuntu/.cpan/prefs],
+ 'prefs_dir' => q[/home/{{ teuthology_user }}/.cpan/prefs],
'prerequisites_policy' => q[follow],
'scan_cache' => q[atstart],
'shell' => q[/bin/bash],
# {{ ansible_managed }}
-ubuntu hard nofile 16384
+{{ teuthology_user }} hard nofile 16384
## Allows people in group wheel to run all commands
%wheel ALL=(ALL) ALL
-ubuntu ALL=(ALL) NOPASSWD:ALL
+{{ teuthology_user }} ALL=(ALL) NOPASSWD:ALL