Skip to content

Commit

Permalink
[distros] Dropped support for Debian 9 and Ubuntu 16 #169
Browse files Browse the repository at this point in the history
Closes #169
  • Loading branch information
nemesifier committed Feb 29, 2020
1 parent c7f1c68 commit c246b7f
Show file tree
Hide file tree
Showing 8 changed files with 27 additions and 52 deletions.
20 changes: 10 additions & 10 deletions .gitlab-ci.yml
Expand Up @@ -101,23 +101,23 @@ terraform-apply:
dependencies:
- terraform-plan

Ubuntu1604:
variables:
distro: 'ubuntu:16.04'
playbook: test.yml
<<: *testing_script
# Ubuntu1604:
# variables:
# distro: 'ubuntu:16.04'
# playbook: test.yml
# <<: *testing_script

Ubuntu1804:
variables:
distro: 'ubuntu:18.04'
playbook: test.yml
<<: *testing_script

Debian9:
variables:
distro: debian:9
playbook: test.yml
<<: *testing_script
# Debian9:
# variables:
# distro: debian:9
# playbook: test.yml
# <<: *testing_script

Debian10:
variables:
Expand Down
19 changes: 9 additions & 10 deletions .travis.yml
Expand Up @@ -11,27 +11,26 @@ env:
matrix:
- distro: 'ubuntu:18.04'
playbook: test.yml
- distro: debian:9
playbook: test.yml
- distro: debian:10
playbook: test.yml
- distro: 'ubuntu:18.04'
playbook: test_networktopology.yml
# we don't have the resources now to maintain these distros
# - distro: debian:9
# playbook: test.yml
# - distro: fedora:27
# playbook: test.yml
# - distro: fedora:28
# playbook: test.yml
# - distro: centos:7
# playbook: test.yml

matrix:
include:
- dist: trusty
python: "3.5"
env:
- distro: 'ubuntu:16.04'
playbook: test.yml
# matrix:
# include:
# - dist: trusty
# python: "3.5"
# env:
# - distro: 'ubuntu:16.04'
# playbook: test.yml

script:
# Configure test script so we can run extra tests after playbook is run.
Expand Down
5 changes: 1 addition & 4 deletions README.md
Expand Up @@ -145,7 +145,6 @@ Substitute `openwisp2.mydomain.com` with your **production server**'s hostname -
`openwisp2.mydomain.com` WITH AN IP ADDRESS**, otherwise email sending through postfix will break,
causing 500 internal server errors on some operations.


Create playbook file
--------------------

Expand Down Expand Up @@ -273,9 +272,7 @@ Pull docker image with this command:
Substitute `<distro>` with one of these variants:

* `ubuntu:18.04`
* `ubuntu:16.04`
* `debian:10`
* `debian:9`

**Step 4**: Run docker container

Expand Down Expand Up @@ -322,7 +319,7 @@ customisations of *OpenWISP*.
### Installing Debian 9 on VirtualBox

Install [VirtualBox](https://virtualbox.org) and create a new Virtual Machine running
Debian 9. A step-by-step guide is available
Debian 10. A step-by-step guide is available
[here](http://www.brianlinkletter.com/installing-debian-linux-in-a-virtualbox-virtual-machine/),
however we need to change a few things to get ansible working.

Expand Down
2 changes: 1 addition & 1 deletion handlers/main.yml
Expand Up @@ -4,7 +4,7 @@

- name: reload systemd
systemd: daemon_reload=yes
when: ansible_distribution_release in ['xenial', 'bionic'] and ansible_service_mgr == 'systemd'
when: ansible_distribution_release in ['bionic'] and ansible_service_mgr == 'systemd'

- name: reload supervisor
command: supervisorctl reload
Expand Down
8 changes: 6 additions & 2 deletions meta/main.yml
Expand Up @@ -16,11 +16,15 @@ galaxy_info:
platforms:
- name: Debian
versions:
- stretch
# (send patch if you want this to be supported!)
# https://github.com/openwisp/ansible-openwisp2/issues/169#issuecomment-592983139
# - stretch
- buster
- name: Ubuntu
versions:
- xenial
# (send patch if you want this to be supported!)
# https://github.com/openwisp/ansible-openwisp2/issues/169#issuecomment-592983139
# - xenial
- bionic
# we don't have the resources now to maintain these distros
# - name: Fedora
Expand Down
8 changes: 0 additions & 8 deletions tasks/apt.yml
Expand Up @@ -103,14 +103,6 @@
register: result
until: result is success

- name: Install python3-pyparsing
when: ansible_distribution == "Debian" and ansible_distribution_version == "9.0"
apt: name=python3-pyparsing
retries: 5
delay: 10
register: result
until: result is success

- name: Install python wheel (optional, allowed to fail)
ignore_errors: yes
apt:
Expand Down
9 changes: 0 additions & 9 deletions tasks/variables-spatialite.yml
Expand Up @@ -6,12 +6,3 @@
and ansible_distribution_version is version_compare('18.04', 'ge'))
or (ansible_distribution == 'Debian' and
ansible_distribution_version is version_compare('10', 'ge'))
- name: Set spatialite_path (Ubuntu >= 16.04 or Debian >= 9)
set_fact:
openwisp2_spatialite_path: "mod_spatialite"
when: >
(ansible_distribution == 'Ubuntu'
and ansible_distribution_version is version_compare('16.04', 'ge'))
or (ansible_distribution == 'Debian'
and ansible_distribution_version is version_compare('9', 'ge'))
8 changes: 0 additions & 8 deletions tests/runtests.sh
Expand Up @@ -28,18 +28,10 @@ if [ $distro = "centos:7" ]; then
elif [ $distro = "ubuntu:18.04" ]; then
init="/lib/systemd/systemd"
opts="--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
# Ubuntu 16.04
elif [ $distro = "ubuntu:16.04" ]; then
init="/lib/systemd/systemd"
opts="--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
# Debian 10
elif [ $distro = "debian:10" ]; then
init="/lib/systemd/systemd"
opts="--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
# Debian 9
elif [ $distro = "debian:9" ]; then
init="/lib/systemd/systemd"
opts="--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro"
fi

# Run the container using the supplied OS
Expand Down

0 comments on commit c246b7f

Please sign in to comment.