diff --git a/.github/workflows/molecule.yml b/.github/workflows/molecule.yml index 02bd8c4c..8a5e1c7e 100644 --- a/.github/workflows/molecule.yml +++ b/.github/workflows/molecule.yml @@ -7,12 +7,12 @@ jobs: strategy: max-parallel: 4 matrix: - python-version: [3.6, 3.7] + python-version: [3.9, "3.10", 3.11] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} - name: Install dependencies diff --git a/README.md b/README.md index 5a34db83..4b0f099d 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ Environment-specific settings are in the `group_vars` directory. A `certbot` role is also included for automatically generating and renewing trusted SSL certificates with [Let's Encrypt][lets-encrypt]. -**Tested with OS:** Ubuntu 18.04 LTS (64-bit), Ubuntu 16.04 LTS (64-bit). +**Tested with OS:** Ubuntu 22.04 LTS (64-bit), Ubuntu 20.04 LTS (64-bit). **Tested with Cloud Providers:** [Digital Ocean][digital-ocean], [AWS][aws], [Rackspace][rackspace] @@ -313,9 +313,9 @@ to run during deployment in most Django environments. ### Changing the Ubuntu release -The [Vagrantfile](Vagrantfile) uses the Ubuntu 20.04 LTS Vagrant box for a +The [Vagrantfile](Vagrantfile) uses the Ubuntu 22.04 LTS Vagrant box for a 64-bit PC that is published by Canonical in HashiCorp Atlas. To use Ubuntu -18.04 LTS instead, change the `config.vm.box` setting to `ubuntu/bionic64`. +20.04 LTS instead, change the `config.vm.box` setting to `ubuntu/focal64`. ### Changing the Python version used by your application diff --git a/Vagrantfile b/Vagrantfile index a794fa17..6d441031 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -5,7 +5,7 @@ VAGRANTFILE_API_VERSION = "2" Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| - config.vm.box = "ubuntu/focal64" + config.vm.box = "ubuntu/jammy64" config.ssh.forward_agent = false config.vm.define "my-cool-app.local", primary: true do |app| app.vm.hostname = "my-cool-app" diff --git a/docker/Dockerfile b/docker/Dockerfile index 473bc899..4025f427 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,5 +1,5 @@ # Use the official Ubuntu 20.04 base image from the Docker repository -FROM ubuntu:focal +FROM ubuntu:jammy # Allow processes to detect that they are being run in a container ENV container oci diff --git a/group_vars/development/vars.yml b/group_vars/development/vars.yml index 89c5b00b..fa1e756c 100644 --- a/group_vars/development/vars.yml +++ b/group_vars/development/vars.yml @@ -11,7 +11,7 @@ application_name: django_default_project # # More info here: https://launchpad.net/~fkrull/+archive/ubuntu/deadsnakes enable_deadsnakes_ppa: true -virtualenv_python_version: python3.9 +virtualenv_python_version: python3.11 # Git settings. diff --git a/molecule/default/Dockerfile.j2 b/molecule/default/Dockerfile.j2 index 0a605536..10ffd4bb 100644 --- a/molecule/default/Dockerfile.j2 +++ b/molecule/default/Dockerfile.j2 @@ -6,7 +6,7 @@ FROM {{ item.registry.url }}/{{ item.image }} FROM {{ item.image }} {% endif %} -RUN if [ $(command -v apt-get) ]; then apt-get update && apt-get install -y python sudo bash ca-certificates && apt-get clean; \ +RUN if [ $(command -v apt-get) ]; then apt-get update && apt-get install -y python python-is-python3 sudo bash ca-certificates && apt-get clean; \ elif [ $(command -v dnf) ]; then dnf makecache && dnf --assumeyes install python sudo python-devel python2-dnf bash && dnf clean all; \ elif [ $(command -v yum) ]; then yum makecache fast && yum install -y python sudo yum-plugin-ovl bash && sed -i 's/plugins=0/plugins=1/g' /etc/yum.conf && yum clean all; \ elif [ $(command -v zypper) ]; then zypper refresh && zypper install -y python sudo bash python-xml && zypper clean -a; \ diff --git a/molecule/default/molecule.yml b/molecule/default/molecule.yml index 6cdedcf9..3f3f61dd 100644 --- a/molecule/default/molecule.yml +++ b/molecule/default/molecule.yml @@ -6,11 +6,11 @@ driver: lint: | yamllint . platforms: - - name: instance-xenial + - name: instance-jammy groups: - vagrant image: ubuntu - image_version: xenial + image_version: jammy privileged: true - name: instance-focal groups: diff --git a/requirements-dev.txt b/requirements-dev.txt index 993772d0..38981b0d 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -1,6 +1,6 @@ -r requirements.txt -molecule==3.3.4 -molecule-docker==0.2.4 -testinfra==3.2.1 +molecule==4.0.4 +molecule-docker==2.1.0 +pytest-testinfra==7.0.1 yamllint==1.19.0