Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Evok www interface does not support https protocol #14

Open
brzezinol opened this issue Feb 27, 2022 · 1 comment
Open

Evok www interface does not support https protocol #14

brzezinol opened this issue Feb 27, 2022 · 1 comment
Labels
question Further information is requested

Comments

@brzezinol
Copy link

I have a question about installing evok.
I installed evok using this documentation https://github.com/UniPiTechnology/evok#legacy-installation-process-using-a-shell-script-required-for-unipi-11
There is, I assume link to latest vesion of evok "wget https://github.com/UniPiTechnology/evok/archive/2.4.12.zip"
But after install I discover that https is not handled properly.
http hardcoded is still in funtion:

function updateValues() {
	if (legacy_api) {
	    $.ajax({
	    	crossDomain: true,
	    	url: 'http://' + $(location).attr('hostname') + ':' + api_port + '/rest/all',
	        dataType: 'json',
	        success: function (data) {
				$("#unipi_loading_spinner").css('visibility', 'hidden');
	            data = sortResults(data);
	            $.each(data, function (name, msg) {
                        syncDevice(msg);
	            });
	        },
	        error: function (data) {
				$("#unipi_loading_spinner").css('visibility', 'visible');
	        }
	    });

Does mentioned documentation refers to latest version with fix from followin pull?
https://github.com/UniPiTechnology/evok/pull/78

Is there a easy fix or update for this issue ? Because I made a little big installation using evok.

@brzezinol
Copy link
Author

brzezinol commented Feb 27, 2022

Changing line url: 'http://' + $(location).attr('hostname') + ':' + api_port + '/rest/all',
to url: '/rest/all',

fix problem because request will be made using current base addres.
but of course author of this script shuld check what was intention of hardcode http.

the same situation with:
url: 'http://' + $(location).attr('hostname') + ':' + api_port + '/rest/' + device + '/' + circuit + '/',

@brzezinol brzezinol changed the title Evok does not support https protocol Evok www interface does not support https protocol Feb 27, 2022
@kratochvil01 kratochvil01 transferred this issue from UniPiTechnology/evok Apr 22, 2024
@cleveHEX cleveHEX added the question Further information is requested label Apr 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants