Merge ~cjwatson/lp-signing:charm-drop-resource into lp-signing:master

Proposed by Colin Watson
Status: Merged
Approved by: Colin Watson
Approved revision: c70fdbfa7e02b7a0c87de12ed52cfaa1f60b6a51
Merge reported by: Otto Co-Pilot
Merged at revision: not available
Proposed branch: ~cjwatson/lp-signing:charm-drop-resource
Merge into: lp-signing:master
Diff against target: 64 lines (+4/-16)
3 files modified
charm/Makefile (+2/-9)
charm/bundle.yaml.in (+2/-2)
charm/lp-signing/metadata.yaml (+0/-5)
Reviewer Review Type Date Requested Status
Jürgen Gmach Approve
Review via email: mp+440862@code.launchpad.net

Commit message

charm: Drop resource from lp-signing charm

Description of the change

This was only ever for local development convenience, and it's usually much easier to just fetch the resource from Swift. Now that we're trying to upload the charm to Charmhub, having a resource attached to it is an active impediment, because Charmhub doesn't have a good way to deal with optional resources; so just drop it.

To post a comment you must log in.
Revision history for this message
Jürgen Gmach (jugmac00) :
review: Approve
Revision history for this message
Colin Watson (cjwatson) :

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/charm/Makefile b/charm/Makefile
2index 927f2a5..7331993 100644
3--- a/charm/Makefile
4+++ b/charm/Makefile
5@@ -10,8 +10,6 @@ export INTERFACE_PATH := $(TMPDIR)/deps/ols-layers/interface
6 CHARM_WHEELS_DIR := $(TMPDIR)/deps/charm-wheels
7
8 BUILD_LABEL = $(shell git rev-parse HEAD)
9-TARBALL = $(APP_NAME).tar.gz
10-ASSET = ../build/$(BUILD_LABEL)/$(TARBALL)
11
12 CHARMS := lp-signing
13
14@@ -77,15 +75,10 @@ bundle.yaml: bundle.yaml.in tmp/signing.launchpad.test.crt tmp/service-private-k
15 -e "s,%KEY_STORAGE_PRIVATE_KEY%,$$(cat tmp/key-storage-private-key),g" \
16 bundle.yaml.in >bundle.yaml
17
18-deploy: build payload bundle.yaml
19+deploy: build bundle.yaml
20 @echo "Deploying $(APP_NAME)..."
21 @juju deploy ./bundle.yaml
22
23-payload: $(ASSET)
24-$(ASSET):
25- @echo "Building asset for $(BUILD_LABEL)..."
26- @$(MAKE) -C .. build-tarball
27-
28 clean:
29 @find . -name \*.pyc -delete
30 @find . -depth -name '__pycache__' -exec rm -rf '{}' \;
31@@ -134,4 +127,4 @@ setup-jenkaas:
32 sudo snap install --classic charm
33
34 .PHONY: $(foreach charm,$(CHARMS),build-$(charm))
35-.PHONY: all build clean deploy lint payload publish setup-jenkaas
36+.PHONY: all build clean deploy lint publish setup-jenkaas
37diff --git a/charm/bundle.yaml.in b/charm/bundle.yaml.in
38index 6ebf77e..8f16084 100644
39--- a/charm/bundle.yaml.in
40+++ b/charm/bundle.yaml.in
41@@ -18,8 +18,8 @@ applications:
42 build_label: "%BUILD_LABEL%"
43 key_storage_private_keys: '["%KEY_STORAGE_PRIVATE_KEY%"]'
44 service_private_keys: '["%SERVICE_PRIVATE_KEY%"]'
45- resources:
46- lp-signing: "../build/%BUILD_LABEL%/lp-signing.tar.gz"
47+ swift_container_name: "lp-signing-builds"
48+ swift_storage_url: "https://objectstorage.prodstack5.canonical.com/swift/v1/AUTH_4f122c9c86d641cca1406b862ea56ad2"
49 relations:
50 - ["haproxy", "lp-signing"]
51 - ["postgresql:db", "lp-signing:db"]
52diff --git a/charm/lp-signing/metadata.yaml b/charm/lp-signing/metadata.yaml
53index 0a6bd38..00d6bab 100644
54--- a/charm/lp-signing/metadata.yaml
55+++ b/charm/lp-signing/metadata.yaml
56@@ -6,8 +6,3 @@ description: A service for storing keys and signing messages.
57 series:
58 - bionic
59 subordinate: false
60-resources:
61- lp-signing:
62- type: file
63- filename: lp-signing.tar.gz
64- description: Launchpad signing code

Subscribers

People subscribed via source and target branches