Skip to content

Support kube-control v2 schema (#5) #31

Support kube-control v2 schema (#5)

Support kube-control v2 schema (#5) #31

Workflow file for this run

name: Tests
on:
push:
branches:
- main
pull_request:
jobs:
call-inclusive-naming-check:
name: Inclusive Naming
uses: canonical/inclusive-naming/.github/workflows/woke.yaml@main
with:
fail-on-error: "true"
lint-unit:
name: Lint Unit
uses: charmed-kubernetes/workflows/.github/workflows/lint-unit.yaml@main
with:
python: "['3.8', '3.10', '3.12']"
needs:
- call-inclusive-naming-check
charmcraft-build:
name: Build Charm
runs-on: ubuntu-22.04
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Install and prepare LXD snap environment
run: |
sudo apt-get remove -qy lxd lxd-client | true
sudo snap list lxd | true
sudo snap install lxd --channel=latest/stable
sudo snap refresh lxd --channel=latest/stable
sudo lxd waitready
sudo lxd init --auto
sudo chmod a+wr /var/snap/lxd/common/lxd/unix.socket
sudo lxc network set lxdbr0 ipv6.address none
sudo usermod -a -G lxd $USER
sg lxd -c 'lxc version'
- name: Remove Docker
run: |
# https://github.com/canonical/lxd-cloud/blob/f20a64a8af42485440dcbfd370faf14137d2f349/test/includes/lxd.sh#L13-L23
sudo rm -rf /etc/docker
sudo apt-get purge moby-buildx moby-engine moby-cli moby-compose moby-containerd moby-runc -y
sudo iptables -P FORWARD ACCEPT
- name: Install Charmcraft
run: |
sudo snap install charmcraft --classic --channel=latest/stable
- name: Build Charm
run: |
sg lxd -c 'charmcraft pack -v'
- name: Upload charm artifact
uses: actions/upload-artifact@v3
with:
name: aws-cloud-provider.charm
path: ./aws-cloud-provider*.charm
- name: Upload debug artifacts
if: ${{ failure() }}
uses: actions/upload-artifact@v3
with:
name: charmcraft-logs
path: /home/runner/snap/charmcraft/common/cache/charmcraft/log/charmcraft-*.log