Merge ~silverdrake11/landscape-charm:better_makefile into landscape-charm:main

Proposed by Kevin Nasto
Status: Merged
Merged at revision: 478314e3edf42eedc19cfbb43a66aa799780bac9
Proposed branch: ~silverdrake11/landscape-charm:better_makefile
Merge into: landscape-charm:main
Diff against target: 18 lines (+5/-2)
1 file modified
Makefile (+5/-2)
Reviewer Review Type Date Requested Status
Mitch Burton Approve
Review via email:

Commit message

Model name from makefile is the same as directory name

Description of the change

The name was previously hard coded in the model. This makes it so if you have multiple models running at once, they will be unique

Manual testing instructions:
* make build
* after it built, look at "juju model" and inspect the new name
* make clean

To post a comment you must log in.
Revision history for this message
Mitch Burton (mitchburton) wrote :


review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/Makefile b/Makefile
2index 6fb245f..2827c47 100644
3--- a/Makefile
4+++ b/Makefile
5@@ -1,8 +1,11 @@
6+DIRNAME = $(notdir $(shell pwd))
7+DIRNAME := $(addsuffix -auto, $(DIRNAME))
9 build: clean
10 charmcraft pack
11- juju add-model testserver
12+ juju add-model $(DIRNAME)
13 juju deploy ./bundle.yaml
15 clean:
16 -rm *.charm
17- -juju destroy-model -y testserver --force
18+ -juju destroy-model -y $(DIRNAME) --force


People subscribed via source and target branches

to all changes: