Skip to content

fix: workaround for /boot/grub2 #8 (2) #109

fix: workaround for /boot/grub2 #8 (2)

fix: workaround for /boot/grub2 #8 (2) #109

Workflow file for this run

---
name: default-bare
on:
push:
pull_request:
workflow_dispatch:
schedule: # run weekly, every monday 03:00
- cron: '0 3 * * 1'
permissions: {}
jobs:
build:
permissions:
contents: read
runs-on: ${{ matrix.distribution }}-${{ matrix.version }}
continue-on-error: ${{ matrix.experimental }}
strategy:
fail-fast: false
max-parallel: 4
matrix:
include:
- distribution: ubuntu
version: '22.04'
experimental: true
- distribution: ubuntu
version: '20.04'
experimental: false
env:
ANSIBLE_CALLBACKS_ENABLED: profile_tasks
ANSIBLE_EXTRA_VARS: "-e ipv6_grub_disable=true"
steps:
- uses: actions/checkout@v3
with:
path: juju4.ipv6
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.x'
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip
pip3 install ansible-lint flake8 yamllint
which ansible
pip3 install ansible
pip3 show ansible
ls -l $HOME/.local/bin || true
ls -l /opt/hostedtoolcache/Python/3.9.1/x64/bin || true
echo "/opt/hostedtoolcache/Python/3.9.1/x64/bin" >> $GITHUB_PATH
ansible --version
cd $GITHUB_WORKSPACE/juju4.ipv6
[ -f get-dependencies.sh ] && sh -x get-dependencies.sh
{ echo '[defaults]'; echo 'callbacks_enabled = profile_tasks, timer'; echo 'roles_path = ../'; echo 'ansible_python_interpreter: /usr/bin/python3'; } >> ansible.cfg
- name: Add GRUB
run: |
sudo apt-get install -y grub2
- name: run test
run: |
cd $GITHUB_WORKSPACE/juju4.ipv6 && ansible-playbook -i localhost, --connection=local --become -vvv test/integration/default/default.yml ${ANSIBLE_EXTRA_VARS}
env:
PY_COLORS: '1'
ANSIBLE_FORCE_COLOR: '1'
- name: idempotency run
run: |
cd $GITHUB_WORKSPACE/juju4.ipv6 && ansible-playbook -i localhost, --connection=local --become -vvv test/integration/default/default.yml ${ANSIBLE_EXTRA_VARS} | tee /tmp/idempotency.log | grep -q 'changed=0.*failed=0' && (echo 'Idempotence test: pass' && exit 0) || (echo 'Idempotence test: fail' && cat /tmp/idempotency.log && exit 1)
- name: On failure
run: |
ansible -i inventory --connection=local -m setup localhost
if: env.WORKFLOW_CONCLUSION == 'failure' # notify only if failure
- name: After script
run: |
set -x
cat /etc/sysconfig/network || true
ls /etc/init.d/ || true
ls /usr/lib/systemd/system/ || true
ip addr || true
ip route || true
cat /etc/resolv.conf || true
ping -c 1 8.8.8.8 || true
ping -c 1 www.google.com || true
if: ${{ always() }}
continue-on-error: true
- name: After script - grub
run: |
set -x
cat /proc/cmdline
ls -lR /boot || true
cat /etc/default/grub || true
if: ${{ always() }}
continue-on-error: true
- name: After script - sysctl
run: |
set -x
sysctl -a |grep ipv6
if: ${{ always() }}
continue-on-error: true
- name: After script -modprobe
run: |
set -x
cat /etc/modprobe.d/blacklist.conf || true
cat /etc/modprobe.conf || true
if: ${{ always() }}
continue-on-error: true