diff --git a/README.md b/README.md index d4cc1a2..497d79e 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,15 @@ -# base +brainsys base configuration +=========================== + +This roles simply set up some locale, date and packages for my own usage. + +License +------- + +MIT + +Author Information +------------------ + +Written by Ludovic Cartier diff --git a/tasks/date.yml b/tasks/date.yml new file mode 100644 index 0000000..72ce652 --- /dev/null +++ b/tasks/date.yml @@ -0,0 +1,4 @@ +--- +- name: base | set date + shell: + cmd: /usr/bin/timedatectl set-timezone Europe/Paris diff --git a/tasks/locales.yml b/tasks/locales.yml new file mode 100644 index 0000000..9840746 --- /dev/null +++ b/tasks/locales.yml @@ -0,0 +1,5 @@ +--- +- name: locales | configure fr_FR.UTF-8 locale + locale_gen: + name: fr_FR.UTF-8 + state: present diff --git a/tasks/main.yml b/tasks/main.yml new file mode 100644 index 0000000..7ae50df --- /dev/null +++ b/tasks/main.yml @@ -0,0 +1,17 @@ +--- +- name: base | apt update cache + apt: + update_cache: yes + cache_valid_time: 86400 #One day + +- name: base | install base packages + include: packages.yml + +- name: base | configure locales + include: locales.yml + +- name: base | install pip3 packages + include: pip.yml + +- name: base | set datetime + include: date.yml diff --git a/tasks/packages.yml b/tasks/packages.yml new file mode 100644 index 0000000..9e167bf --- /dev/null +++ b/tasks/packages.yml @@ -0,0 +1,26 @@ +--- +- name: base | install base packages + apt: + name: {{ item }} + update_cache: true + state: present + with_items: + - bash-completion + - bsd-mailx + - curl + - deborphan + - git-core + - htop + - iotop + - less + - locales + - ntp + - python3-pip + - rsync + - rsyslog + - screen + - subversion + - sudo + - telnet + - tmux + - vim diff --git a/tasks/pip.yml b/tasks/pip.yml new file mode 100644 index 0000000..4760491 --- /dev/null +++ b/tasks/pip.yml @@ -0,0 +1,9 @@ +--- +- name: pip3 | install package + pip: + name: + - ps_mem + - bpytop + executable: pip3 + when: + - ansible_distribution == 'Debian'