Skip to content

Fix project Vagrantfile for Leap 15.6 and add Vagrant 2.4.x / VirtualBox 7.1.x support#126

Merged
SudKul merged 4 commits into
mainfrom
fix/project-vagrantfile-leap-15.6
Apr 28, 2026
Merged

Fix project Vagrantfile for Leap 15.6 and add Vagrant 2.4.x / VirtualBox 7.1.x support#126
SudKul merged 4 commits into
mainfrom
fix/project-vagrantfile-leap-15.6

Conversation

@SudKul

@SudKul SudKul commented Apr 28, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Repair the project/ Vagrantfile: bump the box to opensuse/Leap-15.6.x86_64 (15.6.13.356) and fix the provision command (sudo su - && zypper update ... was a no-op because sudo su - exits before the && chain runs; replaced with sudo zypper update -y && sudo zypper install -y apparmor-parser).
  • Make both Vagrantfiles (project/ and exercises/) compatible with Vagrant 2.4.x + VirtualBox 7.1.x while preserving compatibility with the existing Vagrant 2.2.10+ / VirtualBox 6.1.x setup. The host-only network IP is moved from 192.168.50.4 to 192.168.56.4 so it falls inside the default 192.168.56.0/21 range that VirtualBox 7.x permits — users no longer need to edit /etc/vbox/networks.conf. The address is also accepted by VirtualBox 6.1.x.
  • Document the Vagrant 2.4.0/2.4.1 + VirtualBox 7.1 unsupported-provider warning in exercises/README.md and recommend Vagrant 2.4.2+.

Test plan

  • vagrant up succeeds on Vagrant 2.2.10+ with VirtualBox 6.1.x using the unmodified project/Vagrantfile.
  • vagrant up succeeds on Vagrant 2.4.2+ with VirtualBox 7.1.x without any edit to /etc/vbox/networks.conf.
  • Guest VM is reachable on the host at 192.168.56.4, and forwarded ports 8080 / 6111 / 6112 respond.
  • Provision step actually installs apparmor-parser (verify with rpm -q apparmor-parser inside the VM).
  • Same checks pass for the exercises/Vagrantfile.

Move the host-only private network from 192.168.50.4 to 192.168.56.4
so it falls inside the default 192.168.56.0/21 range that VirtualBox 7.x
permits without requiring users to edit /etc/vbox/networks.conf. The new
address is also accepted by VirtualBox 6.1.x, keeping backward
compatibility with the existing Vagrant 2.2.10+ setup.

Also document the Vagrant 2.4.0/2.4.1 + VirtualBox 7.1 unsupported
provider warning in exercises/README.md and recommend Vagrant 2.4.2+.

Co-Authored-By: sudkul <sudhanshu.kulshrestha@udacity.com>
@SudKul SudKul requested a review from a team as a code owner April 28, 2026 04:28
@SudKul SudKul requested review from sarah-udacity and removed request for a team April 28, 2026 04:28
- Drop the deprecated 2.7/3.5/3.6/3.7/3.8 matrix entries
  (actions/setup-python can no longer install them on
  ubuntu-latest, which is why those jobs were red).
- Add Python 3.10, 3.11, and 3.12 to the matrix and disable
  fail-fast so a single version's failure no longer cancels
  the rest of the matrix.
- Bump actions/checkout to v4 and actions/setup-python to v5
  (the previously pinned v2 actions are deprecated).
- Install dependencies from project/techtrends/requirements.txt
  and run pytest against project/techtrends/ instead of the
  repo root.
- Treat pytest exit code 5 ("no tests collected") as success
  so the job stays green until tests are added under
  project/techtrends/.

The Manual Workflow / JIRA integration is intentionally left
untouched.

Co-Authored-By: sudkul <sudhanshu.kulshrestha@udacity.com>
SudKul and others added 2 commits April 28, 2026 11:29
The techtrends app was still pinned to Flask 2.1.0 / Werkzeug 2.0.0 /
itsdangerous 2.0.1 (early-2022 versions), while the sibling
exercises/python-helloworld and solutions/python-helloworld
requirements files in this repo are already on Flask 3.1.0. Bring
techtrends to the same modern pin and let pip resolve the matching
Werkzeug and itsdangerous transitively (matching the precedent used
by the python-helloworld files).

Flask 3.x keeps the surface used by techtrends/app.py and init_db.py
intact: `from flask import Flask, jsonify, json, render_template,
request, url_for, redirect, flash`, `from werkzeug.exceptions import
abort`, app.config['SECRET_KEY'], app.route(...), request.form,
flash(), redirect(url_for(...)), render_template(...), and
app.run(...). No app code changes needed.

Supersedes the stale dependabot bumps for techtrends:
  - #108 (flask 2.1.0 -> 2.3.2)
  - #114 (werkzeug 2.0.0 -> 3.0.1)

Co-Authored-By: sudkul <sudhanshu.kulshrestha@udacity.com>
The top-level README only linked to the course homepage; new readers
had no end-to-end commands to actually run anything from this repo.

Add a Quick start section that walks through bringing up the exercise
VM (`exercises/Vagrantfile`) and running the python-helloworld Flask
sample inside it. The walk-through assumes the user already has
Vagrant 2.4.x and VirtualBox 7.1.x installed and exercises the
host-only IP (192.168.56.4) introduced earlier on this branch — so it
doubles as a quick smoke test for the VirtualBox 7.x compatibility
fix.

Co-Authored-By: sudkul <sudhanshu.kulshrestha@udacity.com>
@Dhadhazi

Copy link
Copy Markdown
Contributor
exercises_vm_confirmed project_vm_confirm

Both the project and the exercise VM works with Vagrant 2.4.9 and VirtualBox 7.1.18

@SudKul SudKul marked this pull request as ready for review April 28, 2026 17:46
@SudKul SudKul merged commit 498a476 into main Apr 28, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants