diff --git a/.github/workflows/_charm-quality-checks.yaml b/.github/workflows/_charm-quality-checks.yaml index 43d9222..eed8cda 100644 --- a/.github/workflows/_charm-quality-checks.yaml +++ b/.github/workflows/_charm-quality-checks.yaml @@ -10,6 +10,16 @@ on: type: string description: "The provider to choose for either machine or k8s tests ('lxd' or 'microk8s')" required: true + ip-range-start: + type: string + description: "The first IP address in the address pool for the load balancer to use" + required: false + default: "{{ env.IPADDR }}" + ip-range-end: + type: string + description: "The last IP address in the address pool for the load balancer to use" + required: false + default: "{{ env.IPADDR }}" secrets: CHARMHUB_TOKEN: required: false @@ -79,6 +89,8 @@ jobs: with: charm-path: "${{ inputs.charm-path }}" provider: "${{ inputs.provider }}" + ip-range-start: ${{ inputs.ip-range-start }} + ip-range-end: ${{ inputs.ip-range-end }} codeql: name: CodeQL analysis needs: diff --git a/.github/workflows/_charm-tests-integration.yaml b/.github/workflows/_charm-tests-integration.yaml index e10889c..ef53d81 100644 --- a/.github/workflows/_charm-tests-integration.yaml +++ b/.github/workflows/_charm-tests-integration.yaml @@ -10,6 +10,16 @@ on: type: string description: "The provider to choose for either machine or k8s tests ('lxd' or 'microk8s')" required: true + ip-range-start: + type: string + description: "The first IP address in the address pool for the load balancer to use" + required: false + default: "{{ env.IPADDR }}" + ip-range-end: + type: string + description: "The last IP address in the address pool for the load balancer to use" + required: false + default: "{{ env.IPADDR }}" # Default to bash defaults: @@ -35,14 +45,15 @@ jobs: juju-channel: 3.1/edge provider: lxd - name: Setup operator environment (k8s) - if: inputs.provider == 'microk8s' + if: | + inputs.provider == 'microk8s' uses: charmed-kubernetes/actions-operator@main with: juju-channel: 3.1/edge provider: microk8s channel: 1.26-strict/stable microk8s-group: snap_microk8s - microk8s-addons: "hostpath-storage dns metallb:${{ env.IPADDR }}-${{ env.IPADDR }}" + microk8s-addons: "hostpath-storage dns metallb:${{ inputs.ip-range-start }}-${{ inputs.ip-range-end }}" - name: Run integration tests run: cd ${{ inputs.charm-path }} && tox -vve integration - name: Dump debug log diff --git a/.github/workflows/charm-pull-request.yaml b/.github/workflows/charm-pull-request.yaml index 2e7682e..2369132 100644 --- a/.github/workflows/charm-pull-request.yaml +++ b/.github/workflows/charm-pull-request.yaml @@ -13,6 +13,16 @@ on: default: 'microk8s' required: false type: string + ip-range-start: + type: string + description: "The first IP address in the address pool for the load balancer to use" + required: false + default: "{{ env.IPADDR }}" + ip-range-end: + type: string + description: "The last IP address in the address pool for the load balancer to use" + required: false + default: "{{ env.IPADDR }}" secrets: CHARMHUB_TOKEN: required: false @@ -60,3 +70,5 @@ jobs: with: charm-path: ${{ inputs.charm-path }} provider: ${{ inputs.provider }} + ip-range-start: ${{ inputs.ip-range-start }} + ip-range-end: ${{ inputs.ip-range-end }} diff --git a/.github/workflows/charm-release.yaml b/.github/workflows/charm-release.yaml index 8a9e264..a239fa2 100644 --- a/.github/workflows/charm-release.yaml +++ b/.github/workflows/charm-release.yaml @@ -18,6 +18,16 @@ on: default: 'microk8s' required: false type: string + ip-range-start: + type: string + description: "The first IP address in the address pool for the load balancer to use" + required: false + default: "{{ env.IPADDR }}" + ip-range-end: + type: string + description: "The last IP address in the address pool for the load balancer to use" + required: false + default: "{{ env.IPADDR }}" secrets: CHARMHUB_TOKEN: required: true @@ -36,6 +46,8 @@ jobs: with: charm-path: "${{ inputs.charm-path }}" provider: "${{ inputs.provider }}" + ip-range-start: ${{ inputs.ip-range-start }} + ip-range-end: ${{ inputs.ip-range-end }} release-charm: name: Release Charm and Libraries needs: