Tasmoadmin: Old Commit Revision Unknown

Created on 12 Jul 2018  路  19Comments  路  Source: reloxx13/TasmoAdmin

Heya @reloxx13,

I've added two environment variables to the docker image. BUILD_VERSION and BUILD_REF, both can be used to determine the current version / commit from within a running docker container.

If added these so that tasmoadmin can display the current version / revision instead of unknown. Could you please extent the php code (see http://php.net/manual/en/function.getenv.php) to read these environment variables and display the current version / revision?

example:
BUILD_VERSION: v1.3.1
BUILD_REF: 6db1acbe705f80a395a871ffa443529be156f8e1

Some textual changes i suggest are:

  • replace "Old Commit Revision" with "Current Version" or "Current Release"
  • replace "New Commit Revision" with "New Version" or "New Release"

So in a full example:

Current version v1.3.1 >> New version v1.4.0

As a bonus it would be nice to hyperlink both versions to related GitHub tags

Greetz,
Ray

DONE ENHANCEMENT HOT

All 19 comments

yep, will do :+1:

Awesome 馃槆馃憤馃徑

done (in next release) but i cannot test it.

do you create test docker images local?

i tried it on a raspberry but it fails cuz of the architecture and did not got it fixed now. ate a few hours already 馃挬

guess i need to rape my ubuntu vm for this.

@reloxx13, I simply created v1.5.0-beta1 and enabled pre-release option. After pulling it from docker hub and running it from my Synology NAS (amd64) it gives the following:

screen shot 2018-07-13 at 07 57 24

Besides all warnings, on the SelfUpdate page Current Version Unknown.
screen shot 2018-07-13 at 08 20 19

I checked the environment variables within the running container and they are nicely added.

screen shot 2018-07-13 at 08 24 42

Oo ill check it tonight

try it in firefox pls, this expire date is a chrome issue i think.

Just tested Safari, Chrome and FF, they all show the same results (warnings).

~just installed a fresh docker pull, no problems x.x~

ahaha forget it, errors after login

that's weird, I just deleted the container, the data dir and all tasmoadmin images (so fully fresh install) ... ran the new container with:

docker run -d -v /volume1/docker/tasmoadmin:/data -p8091:80 --name beta-tasmoadmin raymondmm/tasmoadmin:v1.5.0-beta1-alpine-amd64

And it still complains about line 42 of the config.php, which is:

setcookie( "MyConfig", $configJSON, intval( time()+( 8640000000*30 ) ), "/" );

Also the current version remains Unknown.

Any suggestion?

Login page displays fine, but afterwards the warnings appear

TODO: echo "fastcgi_param BUILD_VERSION tagnumber;" >> /etc/nginx/fastcgi_params

@RaymondMouthaan do you now where to put this in best case?

ENV vars are not passed to fcgi without this, thats why php cannot find it.

new beta after this is in.

Not sure what needs to be done within the docker image .. We are not using a fpm image but from what I understand is that we need a php-fpm.conf file with some settings (i.e. clear_env = Yes ??? ) and add this to the docker image while building it?

nuu, same problem exists for our using fcgi

this string:
fastcgi_param BUILD_VERSION tagnumber;

tagnumber = replace with travis variable

needs to be in this file
/etc/nginx/fastcgi_params

in short:
echo "fastcgi_param BUILD_VERSION tagnumber;" >> /etc/nginx/fastcgi_params

the FPM link was just to know how they got it into the docker script.

for docker i think it should be:

RUN echo "fastcgi_param BUILD_VERSION ${BUILD_VERSION};" >> /etc/nginx/fastcgi_params
RUN echo "fastcgi_param BUILD_REF ${BUILD_REF};" >> /etc/nginx/fastcgi_params

Added this after he installation of nginx now.

its working!! :rocket:

pls update :+1:

Just to confirm it is working 馃 馃挴 , yeeeaah!

screen shot 2018-07-13 at 12 33 52

Although I am wondering why it shows v1.4.0 as a newer version, shouldn't this be something like "none" ?

Version comparsion is not set up correctly and will be hard with "-beta".

Currently it just checks if current is not latest

Results in new update for now:
1.3.0 != 1.4.0
1.5.0 != 1.4.0

In past their was no way to have a higher version as the latest :package: so if your current is not latest, their is an update :D

and latest is taken by git releases which looks like its not including pre-releases.
results in: latest git is still 1.4.0

Alright, lets stay at this approach :)

Let's close this issue .. the honour is all yours to release v1.5.0 ;)

Closed

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Zwerver91 picture Zwerver91  路  4Comments

jascdk picture jascdk  路  6Comments

tatunts picture tatunts  路  8Comments

xbmcnut picture xbmcnut  路  8Comments

ascillato picture ascillato  路  7Comments