Commit 40a99324 authored by Phil Höfer's avatar Phil Höfer

Fix database error when using Docker

parent c068cd50
...@@ -4,13 +4,6 @@ APP_LOG_LEVEL=debug ...@@ -4,13 +4,6 @@ APP_LOG_LEVEL=debug
APP_KEY= APP_KEY=
APP_URL=http://localhost APP_URL=http://localhost
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=homestead
DB_USERNAME=homestead
DB_PASSWORD=secret
BROADCAST_DRIVER=log BROADCAST_DRIVER=log
CACHE_DRIVER=file CACHE_DRIVER=file
SESSION_DRIVER=file SESSION_DRIVER=file
......
...@@ -14,13 +14,14 @@ RUN apt-get update && apt-get install -y \ ...@@ -14,13 +14,14 @@ RUN apt-get update && apt-get install -y \
sqlite3 \ sqlite3 \
nodejs \ nodejs \
libpng-dev \ libpng-dev \
unzip \
npm npm
RUN npm install gulp -g RUN npm install gulp -g
COPY . /app COPY . /app
WORKDIR app WORKDIR app
RUN mv config/sumas.xml.example config/sumas.xml && mv .env.example .env RUN mv config/sumas.xml.example config/sumas.xml && mv .env.example .env
RUN composer install RUN composer install --no-plugins --no-scripts
RUN npm install RUN npm install
RUN npm run dev RUN npm run dev
......
...@@ -25,11 +25,13 @@ ...@@ -25,11 +25,13 @@
<div id="sponsors"> <div id="sponsors">
<h2>{{ trans('index.sponsors.head.2') }}</h2> <h2>{{ trans('index.sponsors.head.2') }}</h2>
<ul class="startpage"> <ul class="startpage">
@foreach(DB::table('sponsorenlinks')->where('langcode', 'de')->orderByRaw('LENGTH(linktext)', 'ASC')->get() as $link) @if (getenv('DB_CONNECTION')==='mysql')
<li class="sponsor"> @foreach(DB::table('sponsorenlinks')->where('langcode', 'de')->orderByRaw('LENGTH(linktext)', 'ASC')->get() as $link)
<a href="{{ $link->link }}" target="_blank" rel="noopener"><p>{{ $link->linktext }}</p> <i class="fa fa-external-link"></i></a> <li class="sponsor">
</li> <a href="{{ $link->link }}" target="_blank" rel="noopener"><p>{{ $link->linktext }}</p> <i class="fa fa-external-link"></i></a>
@endforeach </li>
@endforeach
@endif
</ul> </ul>
</div> </div>
</div> </div>
......
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