Skip to content

Commit 618effb

Browse files
authored
[PRA-158] Update OCI resource to latest release (#147)
* chore: Bump OCI resource to latest release (3.5.7) * docs: Add RTD link in metadata.yaml * fix: Add missing S3 CA env var in tox.ini * ci: Add log collection in case of failure * fix: Make path getter more robust
1 parent 7b33406 commit 618effb

File tree

4 files changed

+28
-3
lines changed

4 files changed

+28
-3
lines changed

.github/workflows/ci.yaml

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,4 +179,26 @@ jobs:
179179
AZURE_STORAGE_KEY: ${{ secrets.AZURE_STORAGE_KEY }}
180180
CI_PACKED_CHARMS: ${{ needs.build.outputs.charms }}
181181
run: |
182-
tox run -e ${{ matrix.tox-environments }} -- -m '${{ steps.select-tests.outputs.mark_expression }}'
182+
tox run -e ${{ matrix.tox-environments }} -- -m '${{ steps.select-tests.outputs.mark_expression }}' --keep-models
183+
184+
- name: Collect logs if job failed
185+
if: ${{ failure() }}
186+
run: |
187+
juju-crashdump
188+
189+
# get pods
190+
kubectl get pods -A
191+
192+
# replay juju-debug logs
193+
sudo snap install yq
194+
for model in $(juju models --format yaml | yq '.models[] | .name');
195+
do
196+
echo "Model: $model"
197+
if [[ ${model} != *"controller"* ]];then
198+
juju debug-log --model $model --replay
199+
fi
200+
done
201+
202+
# events
203+
kubectl events -A
204+
echo "Done"

metadata.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ description: |
1414
1515
Apache Spark is a free, open source software project by the Apache Software Foundation.
1616
Users can find out more at the [Spark project page](https://spark.apache.org/).
17+
docs: https://canonical-charmed-spark.readthedocs-hosted.com/main/how-to/spark-history-server
1718
source: https://github.com/canonical/spark-history-server-k8s-operator
1819
issues: https://github.com/canonical/spark-history-server-k8s-operator/issues
1920
website:
@@ -32,7 +33,8 @@ resources:
3233
spark-history-server-image:
3334
type: oci-image
3435
description: OCI image for Spark History Server
35-
upstream-source: ghcr.io/canonical/charmed-spark@sha256:a21e7b2d697fe3cfc61986ac40e60f4e9b6e72c4c2b37b34d3e2a6f46a66a80c # spark-version: 3.5.5
36+
# spark-version: 3.5.7, released on 2026-02-27
37+
upstream-source: ghcr.io/canonical/charmed-spark@sha256:c7eef66beaeff463fdb7b707c630c0574912df8b843d8e3169f358adee2ae706
3638

3739
requires:
3840
s3-credentials:

src/core/domain.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ def secret_key(self) -> str:
6666
@property
6767
def path(self) -> str:
6868
"""Return the path in the S3 bucket."""
69-
return self.relation_data["path"]
69+
return self.relation_data.get("path", "")
7070

7171
@property
7272
def region(self) -> str:

tox.ini

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@ pass_env =
113113
S3_ACCESS_KEY
114114
S3_SECRET_KEY
115115
S3_SERVER_URL
116+
S3_CA_BUNDLE_PATH
116117
commands =
117118
poetry install --with integration
118119
playwright install

0 commit comments

Comments
 (0)