Skip to content

Commit

Permalink
Merge pull request #14 from Oefenweb/consistency-changes
Browse files Browse the repository at this point in the history
Consistency changes
  • Loading branch information
tersmitten authored May 15, 2023
2 parents ac0e4fb + 87321f2 commit 9e09de9
Show file tree
Hide file tree
Showing 11 changed files with 20 additions and 16 deletions.
1 change: 1 addition & 0 deletions .ansible-lint
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
---
warn_list:
- role-name
- name[play]
- name[casing]
6 changes: 4 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ jobs:
python-version: '3.x'

- name: Install test dependencies
run: pip install ansible-lint[community,yamllint]
run: |
pip install ansible-lint
ansible-galaxy install -r requirements.yml
- name: Lint code
run: |
Expand Down Expand Up @@ -59,7 +61,7 @@ jobs:
python-version: '3.x'

- name: Install test dependencies
run: pip install 'ansible${{ matrix.ansible-version }}' molecule[docker] docker
run: pip install 'ansible${{ matrix.ansible-version }}' molecule-plugins[docker] docker

- name: Run Molecule tests
run: |
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Set up (the latest version of) [RStudio (IDE)](https://www.rstudio.com/products/

#### Variables

* `rstudio_version` [default: `2022.02.2-485`]: Version to install
* `rstudio_version` [default: `2023.03.1-446`]: Version to install
* `rstudio_install` [default: `[]`]: Additional packages to install (e.g. `r-base`)

## Dependencies
Expand Down
2 changes: 1 addition & 1 deletion defaults/main.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# defaults file
---
rstudio_version: '2022.02.2-485'
rstudio_version: '2023.03.1-446'
rstudio_install: []
2 changes: 1 addition & 1 deletion molecule/default/converge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
become: true
pre_tasks:
- name: include vars
include_vars: "{{ playbook_dir }}/../../tests/vars/main.yml"
ansible.builtin.include_vars: "{{ playbook_dir }}/../../tests/vars/main.yml"
roles:
- ../../../
10 changes: 5 additions & 5 deletions tasks/install.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# tasks file
---
- name: install | dependencies
apt:
ansible.builtin.apt:
name: "{{ rstudio_dependencies }}"
state: "{{ apt_install_state | default('latest') }}"
update_cache: true
Expand All @@ -10,14 +10,14 @@
- rstudio-install-dependencies

- name: install | additional
apt:
ansible.builtin.apt:
name: "{{ rstudio_install }}"
state: "{{ apt_install_state | default('latest') }}"
tags:
- rstudio-install-additional

- name: install | create (download) directory
file:
ansible.builtin.file:
path: "{{ rstudio_downloads_path }}"
state: directory
owner: root
Expand All @@ -28,7 +28,7 @@
- rstudio-install-download-directory

- name: install | download deb # noqa command-instead-of-module
command: >
ansible.builtin.command: >
curl --silent --show-error --fail --location
{{ rstudio_download_url }}
-o {{ rstudio_downloads_path }}/rstudio-{{ rstudio_version }}-{{ rstudio_machine_map[ansible_machine] }}.deb
Expand All @@ -39,7 +39,7 @@
- rstudio-install-download-deb

- name: install | install deb
apt:
ansible.builtin.apt:
deb: "{{ rstudio_downloads_path }}/rstudio-{{ rstudio_version }}-{{ rstudio_machine_map[ansible_machine] }}.deb"
tags:
- rstudio-install-install
Expand Down
5 changes: 3 additions & 2 deletions tasks/main.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# tasks file
---
- name: include variables
include_vars: "{{ item }}"
ansible.builtin.include_vars: "{{ item }}"
with_first_found:
- "_{{ ansible_distribution_release }}.yml"
- "_{{ ansible_distribution | lower }}.yml"
Expand All @@ -11,7 +11,8 @@
- rstudio
- rstudio-include-variables

- include: install.yml
- name: install
ansible.builtin.import_tasks: install.yml
tags:
- configuration
- rstudio
Expand Down
2 changes: 1 addition & 1 deletion tests/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
become: true
pre_tasks:
- name: include vars
include_vars: "{{ playbook_dir }}/vars/main.yml"
ansible.builtin.include_vars: "{{ playbook_dir }}/vars/main.yml"
roles:
- ../../
2 changes: 1 addition & 1 deletion tests/vagrant.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
become: true
pre_tasks:
- name: include vars
include_vars: "{{ playbook_dir }}/vars/main.yml"
ansible.builtin.include_vars: "{{ playbook_dir }}/vars/main.yml"
roles:
- ../../
2 changes: 1 addition & 1 deletion vars/_default.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# vars file
---
rstudio_download_url: "https://download1.rstudio.org/desktop/bionic/{{ rstudio_machine_map[ansible_machine] }}/rstudio-{{ rstudio_version }}-{{ rstudio_machine_map[ansible_machine] }}.deb"
rstudio_download_url: "https://download1.rstudio.org/electron/bionic/{{ rstudio_machine_map[ansible_machine] }}/rstudio-{{ rstudio_version }}-{{ rstudio_machine_map[ansible_machine] }}.deb"
2 changes: 1 addition & 1 deletion vars/_stretch.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# vars file
---
rstudio_download_url: "https://download1.rstudio.org/desktop/debian9/{{ ansible_machine }}/rstudio-{{ rstudio_version }}-{{ rstudio_machine_map[ansible_machine] }}.deb"
rstudio_download_url: "https://download1.rstudio.org/electron/debian9/{{ ansible_machine }}/rstudio-{{ rstudio_version }}-{{ rstudio_machine_map[ansible_machine] }}.deb"

0 comments on commit 9e09de9

Please sign in to comment.