SUPLA Scripts

Awatar użytkownika
michael
Posty: 1299
Rejestracja: śr lis 09, 2016 8:00 am
Lokalizacja: Wojkowice

W temacie aktualizacji na prywatnych instancjach -Aktualizacja bez problemów, powiadomienia Pushover działają :D

Katujemy dalej ;)
:mrgreen: :mrgreen: :mrgreen:
PioKar
Posty: 411
Rejestracja: czw maja 03, 2018 5:56 am

michael pisze: czw maja 21, 2020 7:39 am W temacie aktualizacji na prywatnych instancjach -Aktualizacja bez problemów, powiadomienia Pushover działają :D

Katujemy dalej ;)
Cześć.
Czy napisałbyś mi linie pleceń do podniesienia wersji skryptów?
Do clouda jest opis i jakoś mi to wychodzi a do skryptów nie znalazłem.
Mam malinę produkcyjną i testową.
Jak zawali się testowa jakoś przeżyję.
Piotr.
Awatar użytkownika
michael
Posty: 1299
Rejestracja: śr lis 09, 2016 8:00 am
Lokalizacja: Wojkowice

PioKar pisze: czw maja 21, 2020 10:46 am
michael pisze: czw maja 21, 2020 7:39 am W temacie aktualizacji na prywatnych instancjach -Aktualizacja bez problemów, powiadomienia Pushover działają :D

Katujemy dalej ;)
Cześć.
Czy napisałbyś mi linie pleceń do podniesienia wersji skryptów?
Do clouda jest opis i jakoś mi to wychodzi a do skryptów nie znalazłem.
Mam malinę produkcyjną i testową.
Jak zawali się testowa jakoś przeżyję.
Piotr.
Pewnie, tutaj jest instrukcja:
https://github.com/fracz/supla-scripts/ ... ew-version
:mrgreen: :mrgreen: :mrgreen:
PioKar
Posty: 411
Rejestracja: czw maja 03, 2018 5:56 am

michael pisze: czw maja 21, 2020 10:58 am
PioKar pisze: czw maja 21, 2020 10:46 am
michael pisze: czw maja 21, 2020 7:39 am W temacie aktualizacji na prywatnych instancjach -Aktualizacja bez problemów, powiadomienia Pushover działają :D

Katujemy dalej ;)
Cześć.
Czy napisałbyś mi linie pleceń do podniesienia wersji skryptów?
Do clouda jest opis i jakoś mi to wychodzi a do skryptów nie znalazłem.
Mam malinę produkcyjną i testową.
Jak zawali się testowa jakoś przeżyję.
Piotr.
Pewnie, tutaj jest instrukcja:
https://github.com/fracz/supla-scripts/ ... ew-version
Dzięki. Ja tam nawet już dziś byłem ale bez zrozumienia.
Ta testowej malinie już podniosłem i stronka scripts się otwiera.
Pozdrawiam. Piotr.
Awatar użytkownika
Lector
Posty: 1398
Rejestracja: pt lis 17, 2017 2:26 pm
Lokalizacja: Poznań
Kontakt:

No i super, teraz po wyłączeniu pompy dostaje informacja ile woda ma stopni :)
Czego nie mogłem zrobić w skrypcie Supla Pushover.
Niespełniony automatyk. :mrgreen:
https://3d-lamp.photos/
Awatar użytkownika
PuteR
Posty: 1421
Rejestracja: śr gru 06, 2017 10:07 am

nie wiem czy ma to związek z aktualizacją, która w sumie przeszła bez problemu ale nie widzę w supla scripts żadnych swoich urządzeń. W cloud wszystko działa prawidłowo co może być przyczyną??

Log wygląda w ten sposób

Kod: Zaznacz cały

pi@RPI-4:~ $ docker logs --tail=50 suplascripts
[Thu May 21 17:54:58.408769 2020] [core:notice] [pid 20] AH00052: child pid 2128 exit signal Segmentation fault (11)
[Thu May 21 17:54:58.409136 2020] [mpm_prefork:notice] [pid 20] AH00169: caught SIGTERM, shutting down
2020-05-21 17:54:58,442 INFO stopped: apache (exit status 0)
  ___ _   _ ___ _      _
 / __| | | | _ \ |    /_\
 \__ \ |_| |  _/ |__ / _ \
 |___/\___/|_| |____/_/ \_\
 / __| __ _ _(_)_ __| |_ ___
 \__ \/ _| '_| | '_ \  _(_-<
 |___/\__|_| |_| .__/\__/__/
               |_| by @fracz
               v4.0.0-beta.2

The encryption key already exists. No changes made.
Cache has been cleared successfully
Database backup has been saved to supla-scripts-20200521175508.sql.gz.
Phinx by Rob Morgan - https://phinx.org. 0.8.1

using config file ./backend/database/phinx-config.php
using config parser php
using migration paths 
 - /var/www/backend/database/migrations
using seed paths 
warning no environment specified, defaulting to: db
using adapter mysql
using database suplascripts

All Done. Took 0.0393s
2020-05-21 17:55:08,925 CRIT Supervisor running as root (no user in config file)
2020-05-21 17:55:08,929 INFO supervisord started with pid 1
2020-05-21 17:55:09,936 INFO spawned: 'apache' with pid 20
2020-05-21 17:55:09,945 INFO spawned: 'cron' with pid 21
AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.19.0.3. Set the 'ServerName' directive globally to suppress this message
[Thu May 21 17:55:10.193654 2020] [ssl:warn] [pid 20] AH01909: 172.19.0.3:443:0 server certificate does NOT include an ID which matches the server name
AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.19.0.3. Set the 'ServerName' directive globally to suppress this message
[Thu May 21 17:55:10.360150 2020] [ssl:warn] [pid 20] AH01909: 172.19.0.3:443:0 server certificate does NOT include an ID which matches the server name
[Thu May 21 17:55:10.372162 2020] [mpm_prefork:notice] [pid 20] AH00163: Apache/2.4.25 (Debian) PHP/7.1.27 OpenSSL/1.0.2r configured -- resuming normal operations
[Thu May 21 17:55:10.372218 2020] [core:notice] [pid 20] AH00094: Command line: 'apache2 -D FOREGROUND'
2020-05-21 17:55:11,373 INFO success: apache entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2020-05-21 17:55:11,374 INFO success: cron entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
172.19.0.3:443 192.168.1.17 - - [21/May/2020:17:56:13 +0000] "GET /api/info HTTP/1.1" 200 3709 "https://puter.net.pl:8092/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 OPR/68.0.3618.104"
172.19.0.3:443 192.168.1.17 - - [21/May/2020:17:56:19 +0000] "POST /api/tokens/new HTTP/1.1" 200 3854 "https://puter.net.pl:8092/login" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 OPR/68.0.3618.104"
172.19.0.3:443 192.168.1.17 - - [21/May/2020:17:56:19 +0000] "GET /api/scenes HTTP/1.1" 200 7754 "https://puter.net.pl:8092/login" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 OPR/68.0.3618.104"
172.19.0.3:443 192.168.1.17 - - [21/May/2020:17:56:19 +0000] "GET /api/scenes/9b1294bd-1710-4dff-ad6f-e7534eb4b276 HTTP/1.1" 200 988 "https://puter.net.pl:8092/dashboard" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 OPR/68.0.3618.104"
172.19.0.3:443 192.168.1.17 - - [21/May/2020:17:56:19 +0000] "GET /api/scenes/234a29ec-488a-4692-95d0-ad28a0bdb063 HTTP/1.1" 200 888 "https://puter.net.pl:8092/dashboard" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 OPR/68.0.3618.104"
172.19.0.3:443 192.168.1.17 - - [21/May/2020:17:56:19 +0000] "GET /api/scenes/4644e697-0357-44d8-a6ea-f3f91ee7471e HTTP/1.1" 200 909 "https://puter.net.pl:8092/dashboard" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 OPR/68.0.3618.104"
172.19.0.3:443 192.168.1.17 - - [21/May/2020:17:56:19 +0000] "GET /api/scenes/b9c572eb-a03d-4502-886c-bb3153547a4f HTTP/1.1" 200 909 "https://puter.net.pl:8092/dashboard" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 OPR/68.0.3618.104"
172.19.0.3:443 192.168.1.17 - - [21/May/2020:17:56:19 +0000] "GET /api/scenes/18ed76e7-8e39-47eb-b8f8-175899b1da09 HTTP/1.1" 200 1003 "https://puter.net.pl:8092/dashboard" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 OPR/68.0.3618.104"

Kod: Zaznacz cały

pi@RPI-4:~ $ docker logs --tail=50 suplascripts-db
200521 17:20:45 [Note] Event Scheduler: Purging the queue. 0 events
200521 17:20:45  InnoDB: Starting shutdown...
200521 17:20:52  InnoDB: Shutdown completed; log sequence number 8954228
200521 17:20:53 [Note] mysqld: Shutdown complete

200521 17:22:39 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
200521 17:22:39 [Note] mysqld (mysqld 5.5.60-0+deb7u1) starting as process 1 ...
200521 17:22:39 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead.
200521 17:22:39 [Note] Plugin 'FEDERATED' is disabled.
200521 17:22:39 InnoDB: The InnoDB memory heap is disabled
200521 17:22:39 InnoDB: Mutexes and rw_locks use GCC atomic builtins
200521 17:22:39 InnoDB: Compressed tables use zlib 1.2.7
200521 17:22:39 InnoDB: Using Linux native AIO
200521 17:22:40 InnoDB: Initializing buffer pool, size = 128.0M
200521 17:22:40 InnoDB: Completed initialization of buffer pool
200521 17:22:40 InnoDB: highest supported file format is Barracuda.
200521 17:22:43  InnoDB: Waiting for the background threads to start
200521 17:22:44 InnoDB: 5.5.60 started; log sequence number 8954228
200521 17:22:44 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306
200521 17:22:44 [Note]   - '0.0.0.0' resolves to '0.0.0.0';
200521 17:22:44 [Note] Server socket created on IP: '0.0.0.0'.
200521 17:22:44 [Note] Event Scheduler: Loaded 0 events
200521 17:22:44 [Note] mysqld: ready for connections.
Version: '5.5.60-0+deb7u1'  socket: '/var/run/mysqld/mysqld.sock'  port: 3306  (Debian)
200521 17:54:59 [Note] mysqld: Normal shutdown

200521 17:54:59 [Note] Event Scheduler: Purging the queue. 0 events
200521 17:54:59  InnoDB: Starting shutdown...
200521 17:55:01  InnoDB: Shutdown completed; log sequence number 8955866
200521 17:55:01 [Note] mysqld: Shutdown complete

200521 17:55:06 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
200521 17:55:06 [Note] mysqld (mysqld 5.5.60-0+deb7u1) starting as process 1 ...
200521 17:55:06 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead.
200521 17:55:06 [Note] Plugin 'FEDERATED' is disabled.
200521 17:55:06 InnoDB: The InnoDB memory heap is disabled
200521 17:55:06 InnoDB: Mutexes and rw_locks use GCC atomic builtins
200521 17:55:06 InnoDB: Compressed tables use zlib 1.2.7
200521 17:55:06 InnoDB: Using Linux native AIO
200521 17:55:06 InnoDB: Initializing buffer pool, size = 128.0M
200521 17:55:06 InnoDB: Completed initialization of buffer pool
200521 17:55:06 InnoDB: highest supported file format is Barracuda.
200521 17:55:06  InnoDB: Waiting for the background threads to start
200521 17:55:07 InnoDB: 5.5.60 started; log sequence number 8955866
200521 17:55:07 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306
200521 17:55:07 [Note]   - '0.0.0.0' resolves to '0.0.0.0';
200521 17:55:07 [Note] Server socket created on IP: '0.0.0.0'.
200521 17:55:07 [Note] Event Scheduler: Loaded 0 events
200521 17:55:07 [Note] mysqld: ready for connections.
Version: '5.5.60-0+deb7u1'  socket: '/var/run/mysqld/mysqld.sock'  port: 3306  (Debian)
Awatar użytkownika
fracz
Posty: 2256
Rejestracja: pt paź 28, 2016 10:56 pm
Lokalizacja: Kraków

Wygląda dobrze. Spróbuj wylogować się i zalogować jeszcze raz. I jest już beta 3.
Awatar użytkownika
PuteR
Posty: 1421
Rejestracja: śr gru 06, 2017 10:07 am

fracz pisze: czw maja 21, 2020 6:03 pm Wygląda dobrze. Spróbuj wylogować się i zalogować jeszcze raz. I jest już beta 3.
hmm no mam jakiś problem chciałem podnieść wersję do beta 3 i mam coś takiego

Kod: Zaznacz cały

pi@RPI-4:~/supla-scripts $ docker/suplascripts.sh restart
Stopping SUPLA Scripts containers
SUPLA Scripts containers has been stopped.
  ___ _   _ ___ _      _
 / __| | | | _ \ |    /_\
 \__ \ |_| |  _/ |__ / _ \
 |___/\___/|_| |____/_/ \_\
 / __| __ _ _(_)_ __| |_ ___
 \__ \/ _| '_| | '_ \  _(_-<
 |___/\__|_| |_| .__/\__/__/
               |_| by @fracz

Starting SUPLA Scripts containers
Building suplascripts
Step 1/10 : FROM php:7.1.27-apache-stretch
 ---> 42b69c7f2cf1
Step 2/10 : WORKDIR /var/www
 ---> Using cache
 ---> 9f21f0d0bd00
Step 3/10 : RUN apt-get update     && apt-get install -y --no-install-recommends       libicu-dev       libpq-dev       ca-certificates       ssl-cert       libcurl4-gnutls-dev       git       unzip       mysql-client       supervisor       cron       wget       zlib1g-dev     && update-ca-certificates     && docker-php-ext-install       pdo_mysql       opcache       curl       zip     && apt-get autoremove     && rm -r /var/lib/apt/lists/*
 ---> Using cache
 ---> 85bb4637404a
Step 4/10 : COPY utils/crontab /etc/cron.d/suplascripts
 ---> Using cache
 ---> afbd4d6acbdb
Step 5/10 : RUN {               echo 'opcache.memory_consumption=128';          echo 'opcache.interned_strings_buffer=8';               echo 'opcache.max_accelerated_files=4000';              echo 'opcache.revalidate_freq=2';              echo 'opcache.fast_shutdown=1';                 echo 'opcache.enable_cli=1';    } > /usr/local/etc/php/conf.d/opcache-recommended.ini     && a2enmod rewrite expires deflate ssl cgi alias env && a2ensite default-ssl     && chmod 0644 /etc/cron.d/suplascripts
 ---> Using cache
 ---> 83640ace1ba3
Step 6/10 : ENV SUPLA_SCRIPTS_VERSION=4.0.0-beta.3
 ---> Using cache
 ---> 35e28cfb8f26
Step 7/10 : RUN wget -nc https://github.com/fracz/supla-scripts/releases/download/v${SUPLA_SCRIPTS_VERSION}/supla-scripts-${SUPLA_SCRIPTS_VERSION}.tar.gz     && tar -xzf supla-scripts-${SUPLA_SCRIPTS_VERSION}.tar.gz -C .     && rm -f supla-scripts-${SUPLA_SCRIPTS_VERSION}.tar.gz     && chown -hR www-data:www-data .
 ---> Running in b1420bee33b5
--2020-05-21 19:06:52--  https://github.com/fracz/supla-scripts/releases/download/v4.0.0-beta.3/supla-scripts-4.0.0-beta.3.tar.gz
Resolving github.com (github.com)... failed: Temporary failure in name resolution.
wget: unable to resolve host address 'github.com'
ERROR: Service 'suplascripts' failed to build: The command '/bin/sh -c wget -nc https://github.com/fracz/supla-scripts/releases/download/v${SUPLA_SCRIPTS_VERSION}/supla-scripts-${SUPLA_SCRIPTS_VERSION}.tar.gz     && tar -xzf supla-scripts-${SUPLA_SCRIPTS_VERSION}.tar.gz -C .     && rm -f supla-scripts-${SUPLA_SCRIPTS_VERSION}.tar.gz     && chown -hR www-data:www-data .' returned a non-zero code: 4
Masz nową pocztę w /var/mail/pi
pi@RPI-4:~/supla-scripts $ 
i po tym zabiegu supla scripts w ogóle nie startuje. Można to jakoś naprawić??
wsosniak
Posty: 718
Rejestracja: sob cze 02, 2018 8:02 am

@fracz
Mam problem z Twoimi skryptami
taki rezultat mam jak próbuje uruchamiać publiczne URL-e :

{"status":500,"message":"SQLSTATE[HY000] [2002] php_network_getaddresses: getaddrinfo failed: Name or service not known (SQL: select * from `scenes` where (`slug` = 3cxxxxxxxxxxxxxxxxxxxx559) limit 1)"}

Taki sam komunikat mam jak poróbuje sie zalogowac na supla.fracz.com .
Zerkniejsz co jest nie tak ?
Widze ze ver 4.0.0 wprowadziłeś . Pewno to jest to .... ?

dzięki!
Gucio2607.
Posty: 508
Rejestracja: wt sie 22, 2017 1:56 pm

Ja to nawet się zalogować nie mogę 🤔
Screenshot_20200522-062440.jpg
Screenshot_20200522-062440.jpg (338.7 KiB) Przejrzano 2739 razy
Zainstalowane:
11x sonoff basic, 1x sonoff gate, 1x Yunshan, 2x H801, 7x sonoff touch(1,2,3 gang), 1x sonoff 4ch PRO
Zablokowany

Wróć do „SUPLA Scripts”