Commit 9e116674 authored by Dominik Hebeler's avatar Dominik Hebeler
Browse files

Switching image to alpine

parent 87d857f9
......@@ -18,22 +18,22 @@ class Opencrawlregengergie extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
$results = $content->xpath('//rss/channel/item');
$count = 0;
$count = 0;
foreach ($results as $result) {
if ($count > 10) {
break;
}
$title = $result->{"title"}->__toString();
$link = $result->{"link"}->__toString();
$title = $result->{"title"}->__toString();
$link = $result->{"link"}->__toString();
$anzeigeLink = $link;
$descr = strip_tags($result->{"description"}->__toString());
$descr = strip_tags($result->{"description"}->__toString());
$this->counter++;
$this->results[] = new \App\Models\Result(
$this->engine,
......@@ -41,7 +41,7 @@ class Opencrawlregengergie extends Searchengine
$link,
$anzeigeLink,
$descr,
$this->engine->{"display-name"},$this->engine->homepage,
$this->engine->{"display-name"}, $this->engine->homepage,
$this->counter
);
$count++;
......
......@@ -21,7 +21,7 @@ class Overture extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......@@ -84,7 +84,7 @@ class Overture extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......
......@@ -20,7 +20,7 @@ class OvertureAds extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......@@ -55,7 +55,7 @@ class OvertureAds extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......
......@@ -18,17 +18,17 @@ class Qip extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
$results = $content->xpath('//channel/item');
foreach ($results as $result) {
$title = $result->{"title"}->__toString();
$link = $result->{"link"}->__toString();
$title = $result->{"title"}->__toString();
$link = $result->{"link"}->__toString();
$anzeigeLink = $link;
$descr = $result->{"description"}->__toString();
$descr = $result->{"description"}->__toString();
$this->counter++;
$this->results[] = new \App\Models\Result(
$this->engine,
......@@ -36,7 +36,7 @@ class Qip extends Searchengine
$link,
$anzeigeLink,
$descr,
$this->engine->{"display-name"},$this->engine->homepage,
$this->engine->{"display-name"}, $this->engine->homepage,
$this->counter
);
}
......
......@@ -23,7 +23,7 @@ class Scopia extends Searchengine
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......@@ -59,7 +59,7 @@ class Scopia extends Searchengine
$result = html_entity_decode($result);
$result = str_replace("&", "&", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
} catch (\Exception $e) {
Log::error("A problem occurred parsing results from $this->name:");
......
......@@ -18,7 +18,7 @@ class Shopzilla extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......@@ -66,7 +66,7 @@ class Shopzilla extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......
......@@ -18,7 +18,7 @@ class Tuhh extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......@@ -29,10 +29,10 @@ class Tuhh extends Searchengine
break;
}
$title = $result->{"title"}->__toString();
$link = $result->{"link"}["href"]->__toString();
$title = $result->{"title"}->__toString();
$link = $result->{"link"}["href"]->__toString();
$anzeigeLink = $link;
$descr = strip_tags($result->{"summary"}->__toString());
$descr = strip_tags($result->{"summary"}->__toString());
$this->counter++;
$this->results[] = new \App\Models\Result(
$this->engine,
......@@ -40,7 +40,7 @@ class Tuhh extends Searchengine
$link,
$anzeigeLink,
$descr,
$this->engine->{"display-name"},$this->engine->homepage,
$this->engine->{"display-name"}, $this->engine->homepage,
$this->counter
);
$count++;
......
......@@ -18,7 +18,7 @@ class Yacyunih extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......@@ -32,10 +32,10 @@ class Yacyunih extends Searchengine
if ($count > 10) {
break;
}
$title = $result->{"title"}->__toString();
$link = $result->{"link"}->__toString();
$title = $result->{"title"}->__toString();
$link = $result->{"link"}->__toString();
$anzeigeLink = $link;
$descr = strip_tags($result->{"description"}->__toString());
$descr = strip_tags($result->{"description"}->__toString());
$this->counter++;
$this->results[] = new \App\Models\Result(
$this->engine,
......@@ -43,7 +43,7 @@ class Yacyunih extends Searchengine
$link,
$anzeigeLink,
$descr,
$this->engine->{"display-name"},$this->engine->homepage,
$this->engine->{"display-name"}, $this->engine->homepage,
$this->counter
);
$count++;
......
......@@ -18,7 +18,7 @@ class Yandex extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......@@ -61,7 +61,7 @@ class Yandex extends Searchengine
{
$result = preg_replace("/\r\n/si", "", $result);
try {
$content = simplexml_load_string($result);
$content = \simplexml_load_string($result);
if (!$content) {
return;
}
......
......@@ -14,7 +14,7 @@ server {
location ~ \.php$ {
try_files $uri /index.php =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php/php7.3-fpm.sock;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
......
......@@ -20,7 +20,7 @@ services:
working_dir: /data
command: /data/init.sh
mgdb:
restart: unless-stopped
restart: on-failure
image: mariadb:latest
command: --default-authentication-plugin=mysql_native_password
environment:
......@@ -34,10 +34,14 @@ services:
- "dependencies"
- "phpdeps"
- "assets"
restart: unless-stopped
build: .
restart: on-failure
build:
context: .
dockerfile: Dockerfile.dev
working_dir: /html
volumes:
- .:/html
- ./config/nginx.conf:/etc/nginx/nginx.conf
- ./config/nginx-default.conf:/etc/nginx/conf.d/default.conf
ports:
- "8080:80"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment