Skip to content

Expose app version number at /api#148

Merged
tomwilkie merged 4 commits intoweaveworks:masterfrom
tomwilkie:145-version
Jun 3, 2015
Merged

Expose app version number at /api#148
tomwilkie merged 4 commits intoweaveworks:masterfrom
tomwilkie:145-version

Conversation

@tomwilkie
Copy link
Contributor

I'm thinking we might want to expose a bunch more stuff at /api, such as what probe addresses we're connected to, what version those probes are etc.

@davkal
Copy link
Contributor

davkal commented Jun 2, 2015

LGTM

Not this displaying this for now.

@tomwilkie
Copy link
Contributor Author

Yes yes, baby steps...

@tomwilkie
Copy link
Contributor Author

This is for #145

@peterbourgon
Copy link
Contributor

What's the concrete use case? I want to avoid adding things to the API because we might want to have them in the future, maybe.

@tomwilkie
Copy link
Contributor Author

This is to show the app version in the UI, for when people file bug reports.

@tomwilkie
Copy link
Contributor Author

@davkal PTAL

app/router.go Outdated

This comment was marked as abuse.

@peterbourgon
Copy link
Contributor

Also I'd propose the following patch:

diff --git a/Makefile b/Makefile
index c2245b2..c171d4f 100644
--- a/Makefile
+++ b/Makefile
@@ -11,7 +11,7 @@ SCOPE_IMAGE=$(DOCKERHUB_USER)/scope
 SCOPE_EXPORT=scope.tar
 SCOPE_UI_BUILD_EXPORT=scope_ui_build.tar
 SCOPE_UI_BUILD_IMAGE=$(DOCKERHUB_USER)/scope-ui-build
-SCOPE_VERSION=$(shell git rev-parse HEAD)
+SCOPE_VERSION=$(shell git rev-parse --short HEAD)

 all: $(SCOPE_EXPORT)

@tomwilkie
Copy link
Contributor Author

Good suggestions. I'll hold off for @davkal as there are a bunch of UI changes too.

@davkal
Copy link
Contributor

davkal commented Jun 3, 2015

Let's move this to the right and make it a bit paler:

diff --git a/client/app/styles/main.less b/client/app/styles/main.less
index 4f9cfa4..6a06eb6 100644
--- a/client/app/styles/main.less
+++ b/client/app/styles/main.less
@@ -58,11 +58,11 @@ body {

 .footer {
   position: absolute;
-  bottom: 32px;
-  padding-left: 64px;
-  width: 100%;
-  height: 1em;
+  bottom: 16px;
+  right: 48px;
   z-index: 20;
+  color: @text-tertiary-color;
+  font-size: 85%;
 }

 .logo {

@davkal
Copy link
Contributor

davkal commented Jun 3, 2015

Yeah, rest looks GTM

tomwilkie added a commit that referenced this pull request Jun 3, 2015
Expose app version number at /api
@tomwilkie tomwilkie merged commit 589cba9 into weaveworks:master Jun 3, 2015
@tomwilkie tomwilkie deleted the 145-version branch June 3, 2015 13:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants