Merge branch 'develop' into feature/new-theme

# Conflicts:
#	.gitignore
#	public/themes/pterodactyl/js/frontend/files/filemanager.min.js
#	public/themes/pterodactyl/js/frontend/files/filemanager.min.js.map
#	public/themes/pterodactyl/js/frontend/serverlist.js
#	resources/themes/pterodactyl/server/files/list.blade.php
This commit is contained in:
Jakob Schrettenbrunner 2017-03-03 23:08:24 +01:00
commit 3a88deb97a
170 changed files with 9023 additions and 2222 deletions

View file

@ -15,4 +15,6 @@ return [
'throttle' => 'Too many login attempts. Please try again in :seconds seconds.',
'password_requirements' => 'Passwords must contain at least one uppercase, lowecase, and numeric character and must be at least 8 characters in length.',
'request_reset' => 'Locate Account',
'2fa_required' => '2-Factor Authentication',
'2fa_failed' => 'The 2FA token provided was invalid.',
];

View file

@ -2,6 +2,7 @@
return [
'email' => 'Email',
'user_identifier' => 'Username or Email',
'password' => 'Password',
'confirm_password' => 'Confirm Password',
'login' => 'Login',
@ -60,4 +61,6 @@ return [
'no' => 'No',
'delete' => 'Delete',
'2fa' => '2FA',
'logout' => 'Logout',
'admin_cp' => 'Admin Control Panel',
];

View file

@ -47,7 +47,7 @@
<p class="login-box-msg">@lang('auth.authentication_required')</p>
<form action="{{ route('auth.login') }}" method="POST">
<div class="form-group has-feedback">
<input type="email" name="email" class="form-control" value="{{ old('email') }}" placeholder="@lang('strings.email')">
<input name="user" class="form-control" value="{{ old('user') }}" placeholder="@lang('strings.user_identifier')">
<span class="fa fa-envelope form-control-feedback"></span>
</div>
<div class="form-group has-feedback">
@ -57,7 +57,7 @@
<div class="row">
<div class="col-xs-8">
<div class="form-group has-feedback">
<input type="checkbox" name="remember_me" id="remember_me" /> <label for="remember_me" class="weight-300">@lang('auth.remember_me')</label>
<input type="checkbox" name="remember" id="remember" /> <label for="remember" class="weight-300">@lang('auth.remember_me')</label>
</div>
</div>
<div class="col-xs-4">

View file

@ -17,12 +17,30 @@
{{-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, --}}
{{-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE --}}
{{-- SOFTWARE. --}}
<html>
<head>
<title>Pterodactyl - You've been added to a Server</title>
</head>
<body>
<center><h1>Pterodactyl - Added to Server</h1></center>
<p>You are recieving this email because you have been added as a subuser for <a href="{{ $url }}">{{ $serverName }}</a> on Pterodactyl Panel.</p>
</body>
</html>
@extends('layouts.auth')
@section('title')
2FA Checkpoint
@endsection
@section('content')
<div class="login-box-body">
<p class="login-box-msg">@lang('auth.2fa_required')</p>
<form action="{{ route('auth.totp') }}" method="POST">
<div class="form-group">
<input type="text" name="2fa_token" class="form-control" placeholder="@lang('strings.2fa_token')">
<span class="fa fa-lock form-control-feedback"></span>
</div>
<div class="row">
<div class="col-xs-12">
{!! csrf_field() !!}
<input type="hidden" name="verify_token" value="{{ $verify_key }}" />
@if($remember)
<input type="hidden" name="remember" value="true" />
@endif
<button type="submit" class="btn btn-primary btn-block btn-flat">@lang('strings.submit')</button>
</div>
</div>
</form>
</div>
@endsection

View file

@ -79,3 +79,48 @@
</div>
</div>
@endsection
@section('footer-scripts')
@parent
<script>
$(document).ready(function() {
$('[data-action="delete"]').click(function (event) {
var self = $(this);
event.preventDefault();
swal({
type: 'error',
title: 'Revoke API Key',
text: 'Once this API key is revoked any applications currently using it will stop working.',
showCancelButton: true,
allowOutsideClick: true,
closeOnConfirm: false,
confirmButtonText: 'Revoke',
confirmButtonColor: '#d9534f',
showLoaderOnConfirm: true
}, function () {
$.ajax({
method: 'DELETE',
url: Router.route('account.api.revoke', { key: self.data('attr') }),
headers: {
'X-CSRF-TOKEN': '{{ csrf_token() }}'
}
}).done(function (data) {
swal({
type: 'success',
title: '',
text: 'API Key has been revoked.'
});
self.parent().parent().slideUp();
}).fail(function (jqXHR) {
console.error(jqXHR);
swal({
type: 'error',
title: 'Whoops!',
text: 'An error occured while attempting to revoke this key.'
});
});
});
});
});
</script>
@endsection

View file

@ -62,8 +62,8 @@
<tr class="dynamic-update" data-server="{{ $server->uuidShort }}">
<td><code>{{ $server->uuidShort }}</code></td>
<td><a href="{{ route('server.index', $server->uuidShort) }}">{{ $server->name }}</a></td>
<td>{{ $server->nodeName }}</td>
<td><code>@if(!is_null($server->ip_alias)){{ $server->ip_alias }}@else{{ $server->ip }}@endif:{{ $server->port }}</code></td>
<td>{{ $server->node->name }}</td>
<td><code>{{ $server->allocation->alias }}:{{ $server->allocation->port }}</code></td>
<td class="text-center hidden-sm hidden-xs"><span data-action="memory">--</span> / {{ $server->memory === 0 ? '&infin;' : $server->memory }} MB</td>
<td class="text-center hidden-sm hidden-xs"><span data-action="cpu" data-cpumax="{{ $server->cpu }}">--</span> %</td>
<td class="text-center" data-action="status">

View file

@ -44,10 +44,12 @@
</div>
@yield('content')
<p class="small text-muted">
Copyright &copy; 2015 - {{ date('Y') }} <a href="https://pterodactyl.io/" target="_blank">Pterodactyl Software &amp; Design</a>.<br />
Copyright &copy; 2015 - {{ date('Y') }} <a href="https://pterodactyl.io/" target="_blank">Pterodactyl Software</a>.<br />
</p>
</div>
{!! Theme::js('vendor/jquery/jquery.min.js') !!}
{!! Theme::js('vendor/bootstrap/bootstrap.min.js') !!}
@if(config('app.phrase_in_context')) {!! Theme::js('js/phraseapp.js') !!} @endif
</body>
</html>

View file

@ -60,7 +60,7 @@
<div class="pull-right hidden-xs small text-gray">
<strong>v</strong> {{ config('app.version') }}
</div>
Copyright &copy; 2015 - {{ date('Y') }} <a href="https://pterodactyl.io/">Pterodactyl Software &amp; Design</a>.
Copyright &copy; 2015 - {{ date('Y') }} <a href="https://pterodactyl.io/">Pterodactyl Software</a>.
</footer>
</div>
@section('footer-scripts')

View file

@ -57,47 +57,21 @@
<div class="navbar-custom-menu">
<ul class="nav navbar-nav">
<li class="dropdown user-menu">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
<a href="{{ route('account') }}" class="dropdown-toggle" data-toggle="dropdown">
<img src="https://www.gravatar.com/avatar/{{ md5(strtolower(Auth::user()->email)) }}?s=160" class="user-image" alt="User Image">
<span class="hidden-xs">{{ Auth::user()->name_first }} {{ Auth::user()->name_last }}</span> <span class="caret"></span>
<span class="hidden-xs">{{ Auth::user()->name_first }} {{ Auth::user()->name_last }}</span>
</a>
<ul class="dropdown-menu" role="menu">
@if(Auth::user()->isRootAdmin())
<li><a href="{{ route('admin.index') }}">@lang('strings.admin_control')</a></li>
@endif
<li><a href="{{ route('auth.logout') }}">@lang('strings.sign_out')</a></li>
</ul>
{{-- <ul class="dropdown-menu">
<li class="user-header">
<p>
<small>Member since Nov. 2012</small>
</p>
</li>
<li class="user-body">
<div class="row">
<div class="col-xs-4 text-center">
<a href="#">Followers</a>
</div>
<div class="col-xs-4 text-center">
<a href="#">Sales</a>
</div>
<div class="col-xs-4 text-center">
<a href="#">Friends</a>
</div>
</div>
</li>
<li class="user-footer">
<div class="pull-left">
<a href="{{ route('admin.index') }}" class="btn btn-default btn-flat">Admin Control</a>
</div>
<div class="pull-right">
<a href="{{ route('auth.logout') }}" class="btn btn-default btn-flat">Sign out</a>
</div>
</li>
</ul> --}}
</li>
@if(Auth::user()->isRootAdmin())
<li>
<li><a href="{{ route('admin.index') }}" data-toggle="tooltip" data-placement="bottom" title="{{ @trans('strings.admin_cp') }}"><i class="fa fa-gears" style="margin-top:4px;padding-bottom:2px;"></i></a></li>
</li>
@endif
<li>
<a href="#" data-action="control-sidebar" data-toggle="tooltip" data-placement="bottom" title="{{ @trans('strings.servers') }}"><i class="fa fa-server" style="margin-top:4px;padding-bottom:2px;"></i></a>
</li>
<li>
<a href="#" data-toggle="control-sidebar"><i class="fa fa-gears" style="margin-top:4px;padding-bottom:2px;"></i></a>
<li><a href="{{ route('auth.logout') }}" data-toggle="tooltip" data-placement="bottom" title="{{ @trans('strings.logout') }}"><i class="fa fa-power-off" style="margin-top:4px;padding-bottom:2px;"></i></a></li>
</li>
</ul>
</div>
@ -116,7 +90,7 @@
<ul class="sidebar-menu">
<li class="header">@lang('navigation.account.header')</li>
<li class="{{ Route::currentRouteName() !== 'account' ?: 'active' }}">
<a href="{{ route('account')}}">
<a href="{{ route('account') }}">
<i class="fa fa-user"></i> <span>@lang('navigation.account.my_account')</span>
</a>
</li>
@ -142,63 +116,81 @@
<i class="fa fa-terminal"></i> <span>@lang('navigation.server.console')</span>
</a>
</li>
<li class="treeview
@if(in_array(Route::currentRouteName(), ['server.files.index', 'server.files.edit', 'server.files.add']))
active
@endif
">
<a href="#">
<i class="fa fa-files-o"></i>
<span>@lang('navigation.server.file_management')</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li class="{{ (Route::currentRouteName() !== 'server.files.index' && Route::currentRouteName() !== 'server.files.edit') ?: 'active' }}"><a href="{{ route('server.files.index', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.file_browser')</a></li>
<li class="{{ Route::currentRouteName() !== 'server.files.add' ?: 'active' }}"><a href="{{ route('server.files.add', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.create_file')</a></li>
</ul>
</li>
<li
@if(in_array(Route::currentRouteName(), ['server.subusers', 'server.subusers.new', 'server.subusers.view']))
class="active"
@endif
>
<a href="{{ route('server.subusers', $server->uuidShort)}}">
<i class="fa fa-users"></i> <span>Subusers</span>
</a>
</li>
<li
@if(in_array(Route::currentRouteName(), ['server.tasks', 'server.tasks.new']))
class="active"
@endif
>
<a href="{{ route('server.tasks', $server->uuidShort)}}">
<i class="fa fa-clock-o"></i> <span>@lang('navigation.server.task_management')</span>
<span class="pull-right-container">
<span class="label label-primary pull-right">{{ \Pterodactyl\Models\Task::select('id')->where('server', $server->id)->where('active', 1)->count() }}</span>
</span>
</a>
</li>
<li class="treeview
@if(in_array(Route::currentRouteName(), ['server.settings.sftp', 'server.settings.databases', 'server.settings.startup', 'server.settings.allocation']))
active
@endif
">
<a href="#">
<i class="fa fa-gears"></i>
<span>@lang('navigation.server.configuration')</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li class="{{ Route::currentRouteName() !== 'server.settings.allocation' ?: 'active' }}"><a href="{{ route('server.settings.allocation', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.port_allocations')</a></li>
<li class="{{ Route::currentRouteName() !== 'server.settings.sftp' ?: 'active' }}"><a href="{{ route('server.settings.sftp', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.sftp_settings')</a></li>
<li class="{{ Route::currentRouteName() !== 'server.settings.startup' ?: 'active' }}"><a href="{{ route('server.settings.startup', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.startup_parameters')</a></li>
<li class="{{ Route::currentRouteName() !== 'server.settings.databases' ?: 'active' }}"><a href="{{ route('server.settings.databases', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.databases')</a></li>
</ul>
</li>
@can('list-files', $server)
<li class="treeview
@if(in_array(Route::currentRouteName(), ['server.files.index', 'server.files.edit', 'server.files.add']))
active
@endif
">
<a href="#">
<i class="fa fa-files-o"></i>
<span>@lang('navigation.server.file_management')</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li class="{{ (Route::currentRouteName() !== 'server.files.index' && Route::currentRouteName() !== 'server.files.edit') ?: 'active' }}"><a href="{{ route('server.files.index', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.file_browser')</a></li>
@can('create-files', $server)
<li class="{{ Route::currentRouteName() !== 'server.files.add' ?: 'active' }}"><a href="{{ route('server.files.add', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.create_file')</a></li>
@endcan
</ul>
</li>
@endcan
@can('list-subusers', $server)
<li
@if(in_array(Route::currentRouteName(), ['server.subusers', 'server.subusers.new', 'server.subusers.view']))
class="active"
@endif
>
<a href="{{ route('server.subusers', $server->uuidShort)}}">
<i class="fa fa-users"></i> <span>Subusers</span>
</a>
</li>
@endcan
@can('list-tasks', $server)
<li
@if(in_array(Route::currentRouteName(), ['server.tasks', 'server.tasks.new']))
class="active"
@endif
>
<a href="{{ route('server.tasks', $server->uuidShort)}}">
<i class="fa fa-clock-o"></i> <span>@lang('navigation.server.task_management')</span>
<span class="pull-right-container">
<span class="label label-primary pull-right">{{ \Pterodactyl\Models\Task::select('id')->where('server', $server->id)->where('active', 1)->count() }}</span>
</span>
</a>
</li>
@endcan
@if(Gate::allows('view-startup', $server) || Gate::allows('view-sftp', $server) || Gate::allows('view-databases', $server) || Gate::allows('view-allocation', $server))
<li class="treeview
@if(in_array(Route::currentRouteName(), ['server.settings.sftp', 'server.settings.databases', 'server.settings.startup', 'server.settings.allocation']))
active
@endif
">
<a href="#">
<i class="fa fa-gears"></i>
<span>@lang('navigation.server.configuration')</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
@can('view-allocation', $server)
<li class="{{ Route::currentRouteName() !== 'server.settings.allocation' ?: 'active' }}"><a href="{{ route('server.settings.allocation', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.port_allocations')</a></li>
@endcan
@can('view-sftp', $server)
<li class="{{ Route::currentRouteName() !== 'server.settings.sftp' ?: 'active' }}"><a href="{{ route('server.settings.sftp', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.sftp_settings')</a></li>
@endcan
@can('view-startup', $server)
<li class="{{ Route::currentRouteName() !== 'server.settings.startup' ?: 'active' }}"><a href="{{ route('server.settings.startup', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.startup_parameters')</a></li>
@endcan
@can('view-databases', $server)
<li class="{{ Route::currentRouteName() !== 'server.settings.databases' ?: 'active' }}"><a href="{{ route('server.settings.databases', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.databases')</a></li>
@endcan
</ul>
</li>
@endif
@endif
</ul>
</section>
@ -236,7 +228,7 @@
<div class="pull-right hidden-xs small text-gray">
<strong>v</strong> {{ config('app.version') }}
</div>
Copyright &copy; 2015 - {{ date('Y') }} <a href="https://pterodactyl.io/">Pterodactyl Software &amp; Design</a>.
Copyright &copy; 2015 - {{ date('Y') }} <a href="https://pterodactyl.io/">Pterodactyl Software</a>.
</footer>
<aside class="control-sidebar control-sidebar-dark">
<ul class="nav nav-tabs nav-justified control-sidebar-tabs">
@ -245,7 +237,7 @@
<div class="tab-content">
<div class="tab-pane active" id="control-sidebar-servers-tab">
<ul class="control-sidebar-menu">
@foreach (Pterodactyl\Models\Server::getUserServers() as $s)
@foreach (Auth::user()->serverAccessCollection(null, []) as $s)
<li>
<a
@if(isset($server) && isset($node))
@ -254,7 +246,7 @@
@endif
@endif
href="{{ route('server.index', $s->uuidShort) }}">
@if($s->owner === Auth::user()->id)
@if($s->owner_id === Auth::user()->id)
<i class="menu-icon fa fa-user bg-blue"></i>
@else
<i class="menu-icon fa fa-user-o bg-gray"></i>
@ -281,6 +273,8 @@
{!! Theme::js('vendor/adminlte/app.min.js') !!}
{!! Theme::js('js/vendor/socketio/socket.io.min.js') !!}
{!! Theme::js('vendor/bootstrap-notify/bootstrap-notify.min.js') !!}
@if(config('app.phrase_in_context')) {!! Theme::js('js/phraseapp.js') !!} @endif
@show
</body>
</html>

View file

@ -48,8 +48,8 @@
</div>
<div class="box-footer text-center">
@can('power-start', $server)<button class="btn btn-success disabled" data-attr="power" data-action="start">Start</button>@endcan
@can('power-off', $server)<button class="btn btn-primary disabled" data-attr="power" data-action="restart">Restart</button>@endcan
@can('power-restart', $server)<button class="btn btn-danger disabled" data-attr="power" data-action="stop">Stop</button>@endcan
@can('power-restart', $server)<button class="btn btn-primary disabled" data-attr="power" data-action="restart">Restart</button>@endcan
@can('power-stop', $server)<button class="btn btn-danger disabled" data-attr="power" data-action="stop">Stop</button>@endcan
@can('power-kill', $server)<button class="btn btn-danger disabled" data-attr="power" data-action="kill">Kill</button>@endcan
</div>
</div>
@ -88,7 +88,7 @@
{!! Theme::js('js/frontend/console.js') !!}
{!! Theme::js('js/vendor/chartjs/chart.min.js') !!}
{!! Theme::js('js/vendor/jquery/jquery-dateFormat.min.js') !!}
@if($server->a_serviceFile === 'minecraft')
@if($server->service->file === 'minecraft')
{!! Theme::js('js/plugins/minecraft/eula.js') !!}
@endif
@endsection

View file

@ -49,7 +49,7 @@
<th>@lang('strings.port')</th>
<th></th>
</tr>
@foreach ($allocations as $allocation)
@foreach ($server->allocations as $allocation)
<tr>
<td>
<code>{{ $allocation->ip }}</code>
@ -63,7 +63,7 @@
</td>
<td><code>{{ $allocation->port }}</code></td>
<td class="col-xs-2 middle">
@if($allocation->id === $server->allocation)
@if($allocation->id === $server->allocation_id)
<span class="label label-success" data-allocation="{{ $allocation->id }}">@lang('strings.primary')</span>
@else
<span class="label label-default" data-action="set-connection" data-allocation="{{ $allocation->id }}">@lang('strings.make_primary')</span>

View file

@ -51,29 +51,29 @@
@can('view-subuser', $server)<th></th>@endcan
@can('delete-subuser', $server)<th></th>@endcan
</tr>
@foreach($subusers as $user)
@foreach($subusers as $subuser)
<tr>
<td class="text-center middle"><img class="img-circle" src="https://www.gravatar.com/avatar/{{ md5($user->email) }}?s=128" style="height:20px;" alt="User Image"></td>
<td class="middle">{{ $user->username }}
<td class="middle"><code>{{ $user->email }}</code></td>
<td class="text-center middle"><img class="img-circle" src="https://www.gravatar.com/avatar/{{ md5($subuser->user->email) }}?s=128" style="height:20px;" alt="User Image"></td>
<td class="middle">{{ $subuser->user->username }}
<td class="middle"><code>{{ $subuser->user->email }}</code></td>
<td class="middle text-center">
@if($user->use_totp)
@if($subuser->user->use_totp)
<i class="fa fa-lock text-green"></i>
@else
<i class="fa fa-unlock text-red"></i>
@endif
</td>
<td class="middle hidden-xs">{{ $user->created_at }}</td>
<td class="middle hidden-xs">{{ $subuser->user->created_at }}</td>
@can('view-subuser', $server)
<td class="text-center middle">
<a href="{{ route('server.subusers.view', ['server' => $server->uuidShort, 'id' => md5($user->id)]) }}">
<a href="{{ route('server.subusers.view', ['server' => $server->uuidShort, 'id' => $subuser->id]) }}">
<button class="btn btn-xs btn-primary">@lang('server.users.configure')</button>
</a>
</td>
@endcan
@can('delete-subuser', $server)
<td class="text-center middle">
<a href="#/delete/{{ md5($user->id) }}" data-action="delete" data-id="{{ md5($user->id) }}">
<a href="#/delete/{{ $subuser->id }}" data-action="delete" data-id="{{ $subuser->id }}">
<button class="btn btn-xs btn-danger">@lang('strings.revoke')</button>
</a>
</td>
@ -96,4 +96,51 @@
@section('footer-scripts')
@parent
{!! Theme::js('js/frontend/server.socket.js') !!}
<script>
$(document).ready(function () {
$('[data-action="delete"]').click(function (event) {
event.preventDefault();
var self = $(this);
swal({
type: 'warning',
title: 'Delete Subuser',
text: 'This will immediately remove this user from this server and revoke all permissions.',
showCancelButton: true,
showConfirmButton: true,
closeOnConfirm: false,
showLoaderOnConfirm: true
}, function () {
$.ajax({
method: 'DELETE',
url: Router.route('server.subusers.delete', {
server: Pterodactyl.server.uuidShort,
id: self.data('id'),
}),
headers: {
'X-CSRF-TOKEN': $('meta[name="_token"]').attr('content'),
}
}).done(function () {
self.parent().parent().slideUp();
swal({
type: 'success',
title: '',
text: 'Subuser was successfully deleted.'
});
}).fail(function (jqXHR) {
console.error(jqXHR);
var error = 'An error occured while trying to process this request.';
if (typeof jqXHR.responseJSON !== 'undefined' && typeof jqXHR.responseJSON.error !== 'undefined') {
error = jqXHR.responseJSON.error;
}
swal({
type: 'error',
title: 'Whoops!',
text: error
});
});
});
});
});
</script>
@endsection

View file

@ -35,7 +35,7 @@
@section('content')
@can('edit-subuser', $server)
<form action="{{ route('server.subusers.view', [ 'uuid' => $server->uuidShort, 'id' => md5($subuser->id) ]) }}" method="POST">
<form action="{{ route('server.subusers.view', [ 'uuid' => $server->uuidShort, 'id' => $subuser->id ]) }}" method="POST">
@endcan
<div class="row">
<div class="col-sm-12">
@ -45,7 +45,7 @@
<label class="control-label">@lang('server.users.new.email')</label>
<div>
{!! csrf_field() !!}
<input type="email" class="form-control" disabled value="{{ $subuser->a_userEmail }}" />
<input type="email" class="form-control" disabled value="{{ $subuser->user->email }}" />
</div>
</div>
</div>

View file

@ -52,20 +52,21 @@
</tr>
</thead>
<tbody>
@foreach($databases as $db)
@foreach($databases as $database)
<tr>
<td>{{ $db->a_serverName }}</td>
<td>{{ $db->database }}</td>
<td>{{ $db->username }} ({{ $db->remote }})</td>
<td><code>{{ $db->a_host }}:{{ $db->a_port }}</code></td>
<td class="text-center"><a href="/admin/servers/view/{{ $db->a_serverId }}?tab=tab_database"><i class="fa fa-search"></i></a></td>
<td class="text-center"><a href="#" data-action="delete" data-type="delete" data-attr="{{ $db->id }}" class="text-danger"><i class="fa fa-trash-o"></i></a></td>
<td>{{ $database->server->name }}</td>
<td>{{ $database->database }}</td>
<td>{{ $database->username }} ({{ $database->remote }})</td>
<?php $host = $hosts->where('id', $database->db_server)->first(); ?>
<td><code>{{ $host->host }}:{{ $host->port }}</code></td>
<td class="text-center"><a href="/admin/servers/view/{{ $database->server->id }}?tab=tab_database"><i class="fa fa-search"></i></a></td>
<td class="text-center"><a href="#" data-action="delete" data-type="delete" data-attr="{{ $database->id }}" class="text-danger"><i class="fa fa-trash-o"></i></a></td>
</tr>
@endforeach
</tbody>
</table>
<div class="col-md-12 text-center">
{{ $databases->appends('tab', 'tab_databases')->render() }}
{{ $databases->appends(['tab' => 'tab_databases'])->links() }}
</div>
</div>
</div>
@ -86,20 +87,20 @@
</tr>
</thead>
<tbody>
@foreach($dbh as $db)
@foreach($hosts as $database)
<tr>
<td>{{ $db->name }}</td>
<td><code>{{ $db->host }}:{{ $db->port }}</code></td>
<td>{{ $db->username }}</td>
<td class="text-center">{{ $db->c_databases }}</td>
<td>@if(is_null($db->a_linkedNode))<em>unlinked</em>@else{{ $db->a_linkedNode }}@endif</td>
<td class="text-center"><a href="#" class="text-danger" data-action="delete" data-type="delete-server" data-attr="{{ $db->id }}"><i class="fa fa-trash-o"></i></a></td>
<td>{{ $database->name }}</td>
<td><code>{{ $database->host }}:{{ $database->port }}</code></td>
<td>{{ $database->username }}</td>
<td class="text-center">{{ $database->databases_count }}</td>
<td>@if(is_null($database->node))<em>unlinked</em>@else{{ $database->node->name }}@endif</td>
<td class="text-center"><a href="#" class="text-danger" data-action="delete" data-type="delete-server" data-attr="{{ $database->id }}"><i class="fa fa-trash-o"></i></a></td>
</tr>
@endforeach
</tbody>
</table>
<div class="col-md-12 text-center">
{{ $dbh->appends('tab', 'tab_dbservers')->render() }}
{{ $hosts->appends('tab', 'tab_dbservers')->render() }}
</div>
</div>
</div>

View file

@ -47,7 +47,7 @@
<select name="linked_node" class="form-control">
<option>None</option>
@foreach($nodes as $node)
<option value="{{ $node->id }}" @if((int) old('linked_node') === $node->id) selected="selected" @endif>{{ $node->name }} ({{ $node->a_location }})</option>
<option value="{{ $node->id }}" @if((int) old('linked_node') === $node->id) selected="selected" @endif>{{ $node->name }} ({{ $node->location->short }})</option>
@endforeach
</select>
<p class="text-muted"><small>A linked node implies that this Database Server is running on that node and it will be auto-selected when adding a database to servers on that node.</small></p>

View file

@ -41,7 +41,7 @@
</div>
<div class="row">
<div class="col-xs-4 text-center">
<a href="https://discord.gg/QRDZvVm"><button class="btn btn-sm btn-warning" style="width:100%;"><i class="fa fa-fw fa-support"></i> Get Help <small>(via Discord)</small></button></a>
<a href="{{ Version::getDiscord() }}"><button class="btn btn-sm btn-warning" style="width:100%;"><i class="fa fa-fw fa-support"></i> Get Help <small>(via Discord)</small></button></a>
</div>
<div class="col-xs-4 text-center">
<a href="https://docs.pterodactyl.io"><button class="btn btn-sm btn-default" style="width:100%;"><i class="fa fa-fw fa-link"></i> Documentation</button></a>

View file

@ -46,8 +46,8 @@
<tr>
<td><code>{{ $location->short }}</code></td>
<td>{{ $location->long }}</td>
<td class="text-center">{{ $location->a_nodeCount }}</td>
<td class="text-center">{{ $location->a_serverCount }}</td>
<td class="text-center">{{ $location->nodes_count }}</td>
<td class="text-center">{{ $location->servers_count }}</td>
<td class="text-center"><a href="#edit"><i class="fa fa-wrench" data-toggle="modal" data-target="#editModal" data-action="edit" data-id="{{ $location->id }}" data-short="{{ $location->short }}" data-long="{{ $location->long }}"></i></a></td>
<td class="text-center"><a href="#delete" class="text-danger" data-action="delete" data-id="{{ $location->id }}"><i class="fa fa-trash-o"></i></a></td>
</tr>

View file

@ -53,10 +53,10 @@
<tr>
<td class="text-center text-muted left-icon" data-action="ping" data-secret="{{ $node->daemonSecret }}" data-location="{{ $node->scheme }}://{{ $node->fqdn }}:{{ $node->daemonListen }}"><i class="fa fa-fw fa-refresh fa-spin"></i></td>
<td><a href="/admin/nodes/view/{{ $node->id }}">{{ $node->name }}</td>
<td>{{ $node->a_locationName }}</td>
<td>{{ $node->location->short }}</td>
<td class="hidden-xs">{{ $node->memory }} MB</td>
<td class="hidden-xs">{{ $node->disk }} MB</td>
<td class="text-center hidden-xs">{{ $node->a_serverCount }}</td>
<td class="text-center hidden-xs">{{ $node->servers_count }}</td>
<td class="text-center" style="color:{{ ($node->scheme === 'https') ? '#50af51' : '#d9534f' }}"><i class="fa fa-{{ ($node->scheme === 'https') ? 'lock' : 'unlock' }}"></i></td>
<td class="text-center hidden-xs"><i class="fa fa-{{ ($node->public === 1) ? 'eye' : 'eye-slash' }}"></i></td>
</tr>

View file

@ -44,9 +44,9 @@
<div class="form-group col-md-4">
<label for="name" class="control-label">Location</label>
<div>
<select name="location" class="form-control">
<select name="location_id" class="form-control">
@foreach($locations as $location)
<option value="{{ $location->id }}" {{ (old('location') === $location->id) ? 'checked' : '' }}>{{ $location->long }} ({{ $location->short }})</option>
<option value="{{ $location->id }}" {{ (old('location_id') === $location->id) ? 'selected' : '' }}>{{ $location->long }} ({{ $location->short }})</option>
@endforeach
</select>
</div>

View file

@ -60,7 +60,7 @@
<li><a href="#tab_configuration" data-toggle="tab">Configuration</a></li>
<li><a href="#tab_allocation" data-toggle="tab">Allocation</a></li>
<li><a href="#tab_servers" data-toggle="tab">Servers</a></li>
@if(count($servers) === 0)<li><a href="#tab_delete" data-toggle="tab">Delete</a></li>@endif
@if(count($node->servers) === 0)<li><a href="#tab_delete" data-toggle="tab">Delete</a></li>@endif
</ul>
<div class="tab-content">
<div class="tab-pane active" id="tab_about">
@ -83,7 +83,7 @@
</tr>
<tr>
<td>Total Servers</td>
<td>{{ count($servers) }}</td>
<td>{{ count($node->servers) }}</td>
</tr>
<tr>
<td>Memory Allocated</td>
@ -138,9 +138,9 @@
<div class="form-group col-md-4">
<label for="name" class="control-label">Location</label>
<div>
<select name="location" class="form-control">
<select name="location_id" class="form-control">
@foreach($locations as $location)
<option value="{{ $location->id }}" {{ (old('location', $node->location) === $location->id) ? 'checked' : '' }}>{{ $location->long }} ({{ $location->short }})</option>
<option value="{{ $location->id }}" {{ (old('location_id', $node->location) === $location->id) ? 'selected' : '' }}>{{ $location->long }} ({{ $location->short }})</option>
@endforeach
</select>
</div>
@ -309,7 +309,7 @@
<div class="input-group-btn">
<button type="button" class="btn btn-sm btn-primary dropdown-toggle" data-toggle="dropdown"><span class="caret"></span></button>
<ul class="dropdown-menu dropdown-menu-right">
@foreach($allocation_ips as $allocation)
@foreach($node->allocations->unique('ip')->values()->all() as $allocation)
<li data-action="alloc_dropdown_val" data-value="{{ $allocation->ip }}"><a href="#">{{ $allocation->ip }}</a></li>
@endforeach
</ul>
@ -355,17 +355,21 @@
<td></td>
</thead>
<tbody>
@foreach($allocations as $allocation)
<tr>
@foreach($node->allocations as $allocation)
<tr>
<td class="col-sm-3 align-middle">{{ $allocation->ip }}</td>
<td class="col-sm-3 align-middle">
<input class="form-control input-sm" type="text" value="{{ $allocation->ip_alias }}" data-action="set-alias" data-id="{{ $allocation->id }}" placeholder="none" />
<span class="input-loader"><i class="fa fa-refresh fa-spin fa-fw"></i></span>
</td>
<td class="col-sm-2 align-middle">{{ $allocation->port }}</td>
<td class="col-sm-3 align-middle">@if(!is_null($allocation->assigned_to))<a href="{{ route('admin.servers.view', $allocation->assigned_to) }}">{{ $allocation->assigned_to_name }}</a>@endif</td>
<td class="col-sm-3 align-middle">
@if(! is_null($allocation->server))
<a href="{{ route('admin.servers.view', $allocation->server_id) }}">{{ $allocation->server->name }}</a>
@endif
</td>
<td class="col-sm-1 align-middle">
@if(is_null($allocation->assigned_to))
@if(is_null($allocation->server_id))
<a href="#" data-action="deallocate" data-id="{{ $allocation->id }}"><span class="badge label-danger"><i class="fa fa-trash-o"></i></span></a>
@else
<span class="badge label-default"><i class="fa fa-trash-o"></i></span>
@ -376,7 +380,7 @@
</tbody>
</table>
<div class="col-md-12 text-center">
{{ $allocations->appends(['tab' => 'tab_allocation'])->links() }}
{{ $node->allocations->appends(['tab' => 'tab_allocation'])->render() }}
</div>
</div>
</div>
@ -402,11 +406,11 @@
</tr>
</thead>
<tbody>
@foreach($servers as $server)
@foreach($node->servers as $server)
<tr data-server="{{ $server->uuid }}">
<td><a href="/admin/servers/view/{{ $server->id }}">{{ $server->name }}</a></td>
<td><a href="/admin/users/view/{{ $server->owner }}"><code>{{ $server->a_ownerEmail }}</a></a></td>
<td>{{ $server->a_serviceName }}</td>
<td><a href="/admin/users/view/{{ $server->owner_id }}"><code>{{ $server->user->email }}</a></a></td>
<td>{{ $server->service->name }}</td>
<td class="text-center"><span data-action="memory">--</span> / {{ $server->memory === 0 ? '&infin;' : $server->memory }} MB</td>
<td class="text-center">{{ $server->disk }} MB</td>
<td class="text-center"><span data-action="cpu" data-cpumax="{{ $server->cpu }}">--</span> %</td>
@ -415,13 +419,10 @@
@endforeach
</tbody>
</table>
<div class="row">
<div class="col-md-12 text-center">{!! $servers->appends(['tab' => 'tab_servers'])->render() !!}</div>
</div>
</div>
</div>
</div>
@if(count($servers) === 0)
@if(count($node->servers) === 0)
<div class="tab-pane" id="tab_delete">
<div class="panel panel-default">
<div class="panel-heading"></div>
@ -459,7 +460,7 @@
<div class="row">
<div class="col-md-12">
<select class="form-control" name="ip">
@foreach($allocation_ips as $allocation)
@foreach($node->allocations->unique('ip')->values()->all() as $allocation)
<option value="{{ $allocation->ip }}">{{ $allocation->ip }}</option>
@endforeach
</select>

View file

@ -32,7 +32,7 @@
<h3>All Servers</h3><hr />
<form method="GET" style="margin-bottom:20px;">
<div class="input-group">
<input type="text" name="filter" class="form-control" value="{{ urldecode(Input::get('filter')) }}" placeholder="search term" />
<input type="text" name="filter" class="form-control" value="{{ urldecode(request()->filter) }}" placeholder="search term" />
<div class="input-group-btn">
<button type="submit" class="btn btn-sm btn-primary">Filter Servers</button>
</div>
@ -64,8 +64,8 @@
<span class="label label-danger">Pending Deletion</span>
@endif
</td>
<td><a href="/admin/users/view/{{ $server->owner }}">{{ $server->a_ownerEmail }}</a></td>
<td><a href="/admin/nodes/view/{{ $server->node }}">{{ $server->a_nodeName }}</a></td>
<td><a href="/admin/users/view/{{ $server->user->id }}">{{ $server->user->email }}</a></td>
<td><a href="/admin/nodes/view/{{ $server->node->id }}">{{ $server->node->name }}</a></td>
<td class="hidden-xs"><code>{{ $server->username }}</code></td>
</tr>
@endforeach

View file

@ -63,7 +63,7 @@
<div class="form-group col-md-6">
<label for="location" class="control-label">Server Location</label>
<div>
<select name="location" id="getLocation" class="form-control">
<select name="location_id" id="getLocation" class="form-control">
<option disabled selected> -- Select a Location</option>
@foreach($locations as $location)
<option value="{{ $location->id }}">{{ $location->long }} ({{ $location->short }})</option>
@ -75,7 +75,7 @@
<div class="form-group col-md-6 hidden" id="allocationNode">
<label for="node" class="control-label">Server Node</label>
<div>
<select name="node" id="getNode" class="form-control">
<select name="node_id" id="getNode" class="form-control">
<option disabled selected> -- Select a Node</option>
</select>
<p class="text-muted"><small>The node which this server will be deployed to.</small></p>
@ -181,9 +181,9 @@
<div class="row">
<div class="ajax_loading_box" style="display:none;"><i class="fa fa-refresh fa-spin ajax_loading_position"></i></div>
<div class="form-group col-md-12">
<label for="service" class="control-label">Service Type</label>
<label for="service_id" class="control-label">Service Type</label>
<div>
<select name="service" id="getService" class="form-control">
<select name="service_id" id="getService" class="form-control">
<option disabled selected> -- Select a Service</option>
@foreach($services as $service)
<option value="{{ $service->id }}">{{ $service->name }}</option>
@ -193,18 +193,18 @@
</div>
</div>
<div class="form-group col-md-12 hidden">
<label for="option" class="control-label">Service Option</label>
<label for="option_id" class="control-label">Service Option</label>
<div>
<select name="option" id="getOption" class="form-control">
<select name="option_id" id="getOption" class="form-control">
<option disabled selected> -- Select a Service Option</option>
</select>
<p class="text-muted"><small>Select the type of service that this server will be running.</small></p>
</div>
</div>
<div class="form-group col-md-12 hidden">
<label for="option" class="control-label">Service Pack</label>
<label for="pack_id" class="control-label">Service Pack</label>
<div>
<select name="pack" id="getPack" class="form-control">
<select name="pack_id" id="getPack" class="form-control">
<option disabled selected> -- Select a Service Pack</option>
</select>
<p class="text-muted"><small>Select the service pack that should be used for this server. This option can be changed later.</small></p>
@ -230,7 +230,7 @@
</div>
</div>
</div>
<div class="well" id="serviceOptions" style="display:none;">
<div class="well" id="ServiceOption" style="display:none;">
<div class="row">
<div class="form-group col-md-12">
<h3 class="nopad">Service Setup &amp; Options</h3>
@ -248,7 +248,7 @@
<div class="alert alert-info">Some service options have additional environment variables that you can define for a given instance. They will show up below when you select a service option. If none show up, chances are that none were defined, and there is nothing to worry about.</div>
</div>
</div>
<div class="row" id="serverVariables"></div>
<div class="row" id="ServerVariable"></div>
</div>
<div class="well">
<div class="row">
@ -399,7 +399,7 @@ $(document).ready(function () {
currentService = $('#getService').val();
handleLoader('#load_services', true);
$('#serviceOptions').slideUp();
$('#ServiceOption').slideUp();
$('#getOption').html('<option disabled selected> -- Select a Service Option</option>');
$('#getPack').html('<option disabled selected> -- Select a Service Pack</option>');
@ -430,8 +430,8 @@ $(document).ready(function () {
$('#getOption').on('change', function (event) {
handleLoader('#load_services', true);
handleLoader('#serviceOptions', true);
$('#serverVariables').html('');
handleLoader('#ServiceOption', true);
$('#ServerVariable').html('');
$('input[name="custom_image_name"]').val($(this).find(':selected').data('image'));
$('#getPack').html('<option disabled selected> -- Select a Service Pack</option>');
@ -466,14 +466,14 @@ $(document).ready(function () {
</div>\
</div>\
';
$('#serverVariables').append(dataAppend);
$('#ServerVariable').append(dataAppend);
});
$('#serviceOptions').slideDown();
$('#ServiceOption').slideDown();
}).fail(function (jqXHR) {
console.error(jqXHR);
}).always(function () {
handleLoader('#load_services');
handleLoader('#serviceOptions');
handleLoader('#ServiceOption');
});
});

View file

@ -89,19 +89,19 @@
</tr>
<tr>
<td>Owner</td>
<td><a href="{{ route('admin.users.view', $server->owner) }}">{{ $server->a_ownerEmail }}</a></td>
<td><a href="{{ route('admin.users.view', $server->owner_id) }}">{{ $server->user->email }}</a></td>
</tr>
<tr>
<td>Location</td>
<td><a href="{{ route('admin.locations') }}">{{ $node->a_locationName }}</a></td>
<td><a href="{{ route('admin.locations') }}">{{ $server->node->location->short }}</a></td>
</tr>
<tr>
<td>Node</td>
<td><a href="{{ route('admin.nodes.view', $server->node) }}">{{ $node->name }}</a></td>
<td><a href="{{ route('admin.nodes.view', $server->node_id) }}">{{ $server->node->name }}</a></td>
</tr>
<tr>
<td>Service</td>
<td>{{ $server->a_serviceName }} :: {{ $server->a_servceOptionName }}</td>
<td>{{ $server->option->service->name }} :: {{ $server->option->name }}</td>
</tr>
<tr>
<td>Name</td>
@ -129,13 +129,13 @@
</tr>
<tr>
<td>Default Connection</td>
<td><code>{{ $server->ip }}:{{ $server->port }}</code></td>
<td><code>{{ $server->allocation->ip }}:{{ $server->allocation->port }}</code></td>
</tr>
<tr>
<td>Connection Alias</td>
<td>
@if(!is_null($server->ip_alias))
<code>{{ $server->ip_alias }}:{{ $server->port }}</code>
@if($server->allocation->alias !== $server->allocation->ip)
<code>{{ $server->allocation->alias }}:{{ $server->allocation->port }}</code>
@else
<span class="label label-default">No Alias Assigned</span>
@endif
@ -170,7 +170,7 @@
<div class="form-group {{ $errors->has('owner') ? 'has-error' : '' }}">
<label for="name" class="control-label">Server Owner</label>
<div>
<input type="text" name="owner" value="{{ old('owner', $server->a_ownerEmail) }}" class="form-control" />
<input type="text" name="owner" value="{{ old('owner', $server->user->email) }}" class="form-control" />
<p class="text-muted"><small>You can change the owner of this server by changing this field to an email matching another use on this system. If you do this a new daemon security token will be generated automatically.</small></p>
</div>
</div>
@ -278,9 +278,15 @@
@foreach ($assigned as $assignment)
<div class="input-group" style="margin:5px auto;">
<span class="input-group-addon">
<input type="radio" @if($assignment->ip == $server->ip && $assignment->port == $server->port) checked="checked" @endif name="default" value="{{ $assignment->ip }}:{{ $assignment->port }}"/>
<input type="radio"
@if($assignment->id === $server->allocation_id) checked="checked" @endif
name="default" value="{{ $assignment->ip }}:{{ $assignment->port }}"/>
</span>
<input type="text" class="form-control" value="@if(!is_null($assignment->ip_alias)){{ $assignment->ip_alias }}@else{{ $assignment->ip }}@endif:{{ $assignment->port }} @if(!is_null($assignment->ip_alias))(alias of {{ $assignment->ip }})@endif" readonly />
<input type="text" class="form-control" value="{{ $assignment->alias }}:{{ $assignment->port }}"
@if($assignment->has_alias)
data-toggle="tooltip" data-placement="left" title="{{ $assignment->ip }}:{{ $assignment->port }}"
@endif
/>
</div>
@endforeach
</div>
@ -291,7 +297,7 @@
<div>
<select name="add_additional[]" class="form-control" multiple>
@foreach ($unassigned as $assignment)
<option value="{{ $assignment->ip }}:{{ $assignment->port }}">@if(!is_null($assignment->ip_alias)){{ $assignment->ip_alias }}@else{{ $assignment->ip }}@endif:{{ $assignment->port }} @if(!is_null($assignment->ip_alias))(alias of {{ $assignment->ip }})@endif</option>
<option value="{{ $assignment->ip }}:{{ $assignment->port }}">{{ $assignment->alias }}:{{ $assignment->port }}</option>
@endforeach
</select>
</div>
@ -304,7 +310,7 @@
<div>
<select name="remove_additional[]" class="form-control" multiple>
@foreach ($assigned as $assignment)
<option value="{{ $assignment->ip }}:{{ $assignment->port }}" @if($server->allocation === $assignment->id)disabled @endif>@if(!is_null($assignment->ip_alias)){{ $assignment->ip_alias }}@else{{ $assignment->ip }}@endif:{{ $assignment->port }} @if(!is_null($assignment->ip_alias))(alias of {{ $assignment->ip }})@endif</option>
<option value="{{ $assignment->ip }}:{{ $assignment->port }}" @if($server->allocation_id === $assignment->id)disabled @endif>{{ $assignment->alias }}:{{ $assignment->port }}</option>
@endforeach
</select>
</div>
@ -333,7 +339,7 @@
<div class="alert alert-info">Changing any of the values below will require a restart for them to take effect.</div>
<label class="control-label">Server Startup Command</label>
<div class="input-group">
<span class="input-group-addon">{{ $server->a_serviceExecutable }}</span>
<span class="input-group-addon">{{ $server->option->display_executable }}</span>
<input type="text" class="form-control" name="startup" value="{{ old('startup', $server->startup) }}" />
</div>
<p class="text-muted"><small>The following data replacers are avaliable for the startup command: <code>@{{SERVER_MEMORY}}</code>, <code>@{{SERVER_IP}}</code>, and <code>@{{SERVER_PORT}}</code>. They will be replaced with the allocated memory, server ip, and server port respectively.</small></p>
@ -343,18 +349,18 @@
<div class="panel-heading" style="border-top: 1px solid #ddd;"></div>
<div class="panel-body">
<div class="row">
@foreach($startup as $item)
@foreach($server->option->variables as $variable)
<div class="form-group col-md-6">
<label class="control-label">
@if($item->required === 1)<span class="label label-primary">Required</span> @endif
@if($item->user_viewable === 0)<span data-toggle="tooltip" data-placement="top" title="Not Visible to Users" class="label label-danger"><i class="fa fa-eye-slash"></i></span> @endif
@if($item->user_editable === 0)<span data-toggle="tooltip" data-placement="top" title="Not Editable by Users" class="label label-danger"><i class="fa fa-edit"></i></span> @endif
{{ $item->name }}
@if($variable->required)<span class="label label-primary">Required</span> @endif
@if(! $variable->user_viewable)<span data-toggle="tooltip" data-placement="top" title="Not Visible to Users" class="label label-danger"><i class="fa fa-eye-slash"></i></span> @endif
@if(! $variable->user_editable)<span data-toggle="tooltip" data-placement="top" title="Not Editable by Users" class="label label-danger"><i class="fa fa-edit"></i></span> @endif
{{ $variable->name }}
</label>
<div>
<input type="text" name="{{ $item->env_variable }}" class="form-control" value="{{ old($item->env_variable, $item->a_serverValue) }}" data-action="matchRegex" data-regex="{{ $item->regex }}" />
<input type="text" name="{{ $variable->env_variable }}" class="form-control" value="{{ old($variable->env_variable, (! $variable->server_value) ? $variable->default_value : $variable->server_value) }}" data-action="matchRegex" data-regex="{{ $variable->regex }}" />
</div>
<p class="text-muted"><small>{!! $item->description !!}<br />Regex: <code>{{ $item->regex }}</code><br />Access as: <code>&#123;&#123;{{$item->env_variable}}&#125;&#125;</code></small></p>
<p class="text-muted"><small>{!! $variable->description !!}<br />Regex: <code>{{ $variable->regex }}</code><br />Access as: <code>&#123;&#123;{{ $variable->env_variable }}&#125;&#125;</code></small></p>
</div>
@endforeach
</div>
@ -398,7 +404,7 @@
<label class="control-label">Database Server:</label>
<select name="db_server" class="form-control">
@foreach($db_servers as $dbs)
<option value="{{ $dbs->id }}" @if($dbs->linked_node === $server->node)selected="selected"@endif>{{ $dbs->name }} ({{ $dbs->host }}:{{ $dbs->port }})</option>
<option value="{{ $dbs->id }}" @if($dbs->linked_node === $server->node_id)selected="selected"@endif>{{ $dbs->name }} ({{ $dbs->host }}:{{ $dbs->port }})</option>
@endforeach
</select>
</div>
@ -412,7 +418,7 @@
</div>
</form>
</div>
@if(count($databases) > 0)
@if(count($server->databases) > 0)
<div class="panel-heading" style="border-top: 1px solid #ddd;"></div>
<div class="panel-body">
<table class="table table-bordered table-hover">
@ -426,12 +432,12 @@
</th>
</thead>
<tbody>
@foreach($databases as $database)
@foreach($server->databases as $database)
<tr>
<td>{{ $database->database }}</td>
<td>{{ $database->username }} ({{ $database->remote }})</td>
<td><code>{{ Crypt::decrypt($database->password) }}</code> <a href="#" data-action="reset-database-password" data-id="{{ $database->id }}"><i class="fa fa-refresh pull-right"></i></a></td>
<td><code>{{ $database->a_host }}:{{ $database->a_port }}</code></td>
<td><code>{{ $database->host->host }}:{{ $database->host->port }}</code></td>
<td class="text-center"><a href="#delete" data-action="delete_database" data-database="{{ $database->id }}" class="text-danger"><i class="fa fa-trash-o"></i></a></td>
</tr>
@endforeach
@ -568,7 +574,7 @@ $(document).ready(function () {
'X-Access-Token': '{{ $server->daemonSecret }}',
'X-Access-Server': '{{ $server->uuid }}'
},
url: '{{ $node->scheme }}://{{ $node->fqdn }}:{{ $node->daemonListen }}/server',
url: '{{ $server->node->scheme }}://{{ $server->node->fqdn }}:{{ $server->node->daemonListen }}/server',
dataType: 'json',
timeout: 5000,
}).done(function (data) {

View file

@ -44,7 +44,7 @@
<tr>
<td><a href="{{ route('admin.services.service', $service->id) }}">{{ $service->name }}</a></td>
<td>{!! $service->description !!}</td>
<td class="text-center">{{ $service->c_servers }}</td>
<td class="text-center">{{ $service->servers_count }}</td>
<td class="text-center align-middle"><a href="{{ route('admin.services.service.config', $service->id) }}"><button class="btn btn-xxs btn-primary"><i class="fa fa-wrench"></i> Configure</button></a></td>
</tr>
@endforeach

View file

@ -28,12 +28,12 @@
<ul class="breadcrumb">
<li><a href="/admin">Admin Control</a></li>
<li><a href="/admin/services">Services</a></li>
<li><a href="{{ route('admin.services.service', $service->id) }}">{{ $service->name }}</a></li>
<li><a href="{{ route('admin.services.option', [$service->id, $option->id]) }}">{{ $option->name }}</a></li>
<li><a href="{{ route('admin.services.service', $option->service->id) }}">{{ $option->service->name }}</a></li>
<li><a href="{{ route('admin.services.option', [$option->service->id, $option->id]) }}">{{ $option->name }}</a></li>
<li class="active">New Variable</li>
</ul>
<h3>New Option Variable</h3><hr />
<form action="{{ route('admin.services.option.variable.new', [$service->id, $option->id]) }}" method="POST">
<form action="{{ route('admin.services.option.variable.new', [$option->service->id, $option->id]) }}" method="POST">
<div class="well">
<div class="row">
<div class="col-md-12 form-group">

View file

@ -28,12 +28,12 @@
<ul class="breadcrumb">
<li><a href="/admin">Admin Control</a></li>
<li><a href="/admin/services">Services</a></li>
<li><a href="{{ route('admin.services.service', $service->id) }}">{{ $service->name }}</a></li>
<li><a href="{{ route('admin.services.service', $option->service->id) }}">{{ $option->service->name }}</a></li>
<li class="active">{{ $option->name }}</li>
</ul>
<div class="alert alert-warning"><strong>Warning!</strong> This page contains advanced settings that the panel and daemon use to control servers. Modifying information on this page is not recommended unless you are absolutely sure of what you are doing.</div>
<h3>Settings</h3><hr />
<form action="{{ route('admin.services.option', [$service->id, $option->id]) }}" method="POST">
<form action="{{ route('admin.services.option', [$option->service->id, $option->id]) }}" method="POST">
<div class="row">
<div class="col-md-6 form-group">
<label class="control-label">Name:</label>
@ -74,7 +74,7 @@
<div class="col-md-12 form-group">
<label class="control-label">Default Startup Command:</label>
<div>
<input type="text" name="startup" value="{{ old('startup', $option->startup) }}" class="form-control" />
<input type="text" name="startup" value="{{ old('startup', $option->startup) }}" placeholder="{{ $option->service->startup }}" class="form-control" />
<p class="text-muted"><small>To use the default startup of the parent service simply leave this field blank.</small></p>
</div>
</div>
@ -88,9 +88,9 @@
</div>
</div>
</form>
<h3>Variables <small><a href="{{ route('admin.services.option.variable.new', [$service->id, $option->id]) }}"><i class="fa fa-plus"></i></a></small></h3><hr />
@foreach($variables as $variable)
<form action="{{ route('admin.services.option.variable', [$service->id, $option->id, $variable->id]) }}" method="POST">
<h3>Variables <small><a href="{{ route('admin.services.option.variable.new', [$option->service->id, $option->id]) }}"><i class="fa fa-plus"></i></a></small></h3><hr />
@foreach($option->variables as $variable)
<form action="{{ route('admin.services.option.variable', [$option->service->id, $option->id, $variable->id]) }}" method="POST">
<div class="well">
<div class="row">
<div class="col-md-6 form-group">
@ -158,7 +158,7 @@
<div class="row">
<div class="col-md-12">
{!! csrf_field() !!}
<a href="{{ route('admin.services.option.variable.delete', [$service->id, $option->id, $variable->id]) }}"><button type="button" class="btn btn-sm btn-danger pull-right"><i class="fa fa-times"></i></button></a>
<a href="{{ route('admin.services.option.variable.delete', [$option->service->id, $option->id, $variable->id]) }}"><button type="button" class="btn btn-sm btn-danger pull-right"><i class="fa fa-times"></i></button></a>
<input type="submit" class="btn btn-sm btn-success" value="Update Variable" />
</div>
</div>
@ -175,16 +175,19 @@
</tr>
</thead>
<tbody>
@foreach ($servers as $server)
@foreach ($option->servers as $server)
<tr>
<td><a href="{{ route('admin.servers.view', $server->id) }}">{{ $server->name }}</a></td>
<td><a href="{{ route('admin.users.view', $server->owner) }}">{{ $server->a_ownerEmail }}</a></td>
<td><a href="{{ route('admin.users.view', $server->owner_id) }}">{{ $server->user->email }}</a></td>
<td>{{ $server->updated_at }}</td>
</tr>
@endforeach
</tbody>
</table>
<form action="{{ route('admin.services.option', [$service->id, $option->id]) }}" method="POST">
<div class="text-center">
{!! $option->servers->render() !!}
</div>
<form action="{{ route('admin.services.option', [$option->service->id, $option->id]) }}" method="POST">
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger">

View file

@ -29,7 +29,7 @@
<li><a href="/admin">Admin Control</a></li>
<li><a href="/admin/services">Services</a></li>
<li><a href="{{ route('admin.services.packs') }}">Packs</a></li>
<li><a href="{{ route('admin.services.packs.service', $service->id) }}">{{ $service->name }}</a></li>
<li><a href="{{ route('admin.services.packs.service', $option->service->id) }}">{{ $option->service->name }}</a></li>
<li class="active">{{ $option->name }}</li>
</ul>
<h3 class="nopad">Service Packs</h3><hr />
@ -44,7 +44,7 @@
</tr>
</thead>
<tbody>
@foreach ($packs as $pack)
@foreach ($option->packs as $pack)
<tr>
<td><a href="{{ route('admin.services.packs.edit', $pack->id) }}">{{ $pack->name }}</a></td>
<td><code>{{ $pack->version }}</code></td>

View file

@ -40,10 +40,10 @@
</tr>
</thead>
<tbody>
@foreach ($options as $option)
@foreach ($service->options as $option)
<tr>
<td><a href="{{ route('admin.services.packs.option', $option->id) }}">{{ $option->name }}</a></td>
<td>{{ $option->p_count }}</td>
<td>{{ $option->packs->count() }}</td>
</tr>
@endforeach
<tr>

View file

@ -29,8 +29,8 @@
<li><a href="/admin">Admin Control</a></li>
<li><a href="/admin/services">Services</a></li>
<li><a href="{{ route('admin.services.packs') }}">Packs</a></li>
<li><a href="{{ route('admin.services.packs.service', $service->id) }}">{{ $service->name }}</a></li>
<li><a href="{{ route('admin.services.packs.option', $option->id) }}">{{ $option->name }}</a></li>
<li><a href="{{ route('admin.services.packs.service', $pack->option->service->id) }}">{{ $pack->option->service->name }}</a></li>
<li><a href="{{ route('admin.services.packs.option', $pack->option->id) }}">{{ $pack->option->name }}</a></li>
<li class="active">{{ $pack->name }} ({{ $pack->version }})</li>
</ul>
<h3 class="nopad">Manage Service Pack</h3><hr />
@ -62,10 +62,10 @@
<div class="col-md-6">
<label class="control-label">Associated Service Option:</label>
<select name="option" class="form-control">
@foreach($services as $service => $options)
<option disabled>{{ $service }}</option>
@foreach($options as $option)
<option value="{{ $option['id'] }}" @if($pack->id === (int) $option['id'])selected="selected"@endif>&nbsp;&nbsp; -- {{ $option['name'] }}</option>
@foreach($services as $service)
<option disabled>{{ $service->name }}</option>
@foreach($service->options as $option)
<option value="{{ $option->id }}" @if($pack->option_id === $option->id)selected="selected"@endif>&nbsp;&nbsp; -- {{ $option->name }}</option>
@endforeach
@endforeach
</select>
@ -88,64 +88,6 @@
</div>
</div>
<hr />
<div class="row">
<div class="col-md-12">
<h5 class="nopad">Build Parameters</h5>
<div class="well" style="margin-bottom:0">
<div class="row">
<div class="form-group col-md-3 col-xs-6">
<label class="control-label">Memory:</label>
<div class="input-group">
<input type="text" name="build_memory" class="form-control" value="{{ old('build_memory', $pack->build_memory) }}"/>
<span class="input-group-addon">MB</span>
</div>
</div>
<div class="form-group col-md-3 col-xs-6">
<label class="control-label">Swap:</label>
<div class="input-group">
<input type="text" name="build_swap" class="form-control" value="{{ old('build_swap', $pack->build_swap) }}"/>
<span class="input-group-addon">MB</span>
</div>
</div>
<div class="form-group col-md-3 col-xs-6">
<label class="control-label">CPU:</label>
<div class="input-group">
<input type="text" name="build_cpu" class="form-control" value="{{ old('build_cpu', $pack->build_cpu) }}"/>
<span class="input-group-addon">%</span>
</div>
</div>
<div class="form-group col-md-3 col-xs-6">
<label class="control-label">IO:</label>
<div class="input-group">
<input type="text" name="build_io" class="form-control" value="{{ old('build_io', $pack->build_io) }}"/>
<span class="input-group-addon">I/O</span>
</div>
</div>
<div class="form-group col-md-12">
<div>
<p class="text-muted"><small>If you would like to set limits on the build container you may do so above. Setting <code>memory</code>, <code>swap</code>, or <code>cpu</code> to <code>0</code> will allow unlimited resource utilization. IO must be in a range between <code>10</code> to <code>1000</code> and is a relative weighting to other container IO usage.</small></p>
</div>
</div>
</div>
<div class="row">
<div class="form-group col-md-12">
<label class="control-label">Build Container:</label>
<div>
<input type="text" name="build_container" class="form-control" value="{{ old('build_container', $pack->build_container) }}"/>
<p class="text-muted"><small>Provide the docker container image that will be used to build this service pack. This container is <em>only</em> used if a build script is provided below.</small></p>
</div>
</div>
<div class="form-group col-md-12">
<label class="control-label">Build Script:</label>
<div id="build_script" style="height:200px">{{ $pack->build_script }}</div>
<textarea id="editor_contents" name="build_script" class="hidden"></textarea>
<p class="text-muted"><small>This script will be run inside the container if provided. You should use this script to download any additional dependencies or compile packages as necessary on the node. Your uploaded archive (if provided), will be available in <code>/input</code> as <code>archive.tar.gz</code> or as <code>archive.zip</code> depending on what format you uploaded as. Your completed pack should be saved as <code>package.tar.gz</code> in the <code>/output</code> directory (e.g. <code>/output/package.tar.gz</code>).</small></p>
</div>
</div>
</div>
</div>
</div>
<hr />
<div class="row">
<div class="col-md-12">
<h5 class="nopad">Package Archive</h5>
@ -153,7 +95,7 @@
<div class="row">
<div class="form-group col-md-12">
@if(count($files) > 1)
<div class="alert alert-danger"><strong>Warning!</strong> Service packs should only contain a single pack archive in either <code>.zip</code> or <code>.tar.gz</code> format. We've detected more than one file for this pack.</div>
<div class="alert alert-danger"><strong>Warning!</strong> Service packs should only contain a single pack archive in <code>.tar.gz</code> format. We've detected more than one file for this pack.</div>
@endif
<table class="table table-striped">
<thead>
@ -175,7 +117,7 @@
@endforeach
</tbody>
</table>
<p class="text-muted"><small>If you wish to modify or upload a new file it should be uploaded to <code>{{ storage_path('app/packs/' . $pack->uuid) }}</code> as either <code>archive.zip</code> or <code>archive.tar.gz</code>.</small></p>
<p class="text-muted"><small>If you wish to modify or upload a new file it should be uploaded to <code>{{ storage_path('app/packs/' . $pack->uuid) }}</code> as <code>archive.tar.gz</code>.</small></p>
</div>
</div>
</div>

View file

@ -59,10 +59,10 @@
<div class="col-md-6">
<label class="control-label">Associated Service Option:</label>
<select name="option" class="form-control">
@foreach($services as $service => $options)
<option disabled>{{ $service }}</option>
@foreach($options as $option)
<option value="{{ $option['id'] }}" @if((int) $packFor === (int) $option['id'])selected="selected"@endif>&nbsp;&nbsp; -- {{ $option['name'] }}</option>
@foreach($services as $service)
<option disabled>{{ $service->name }}</option>
@foreach($service->options as $option)
<option value="{{ $option->id }}" @if((int) request()->option === $option->id)selected="selected"@endif>&nbsp;&nbsp; -- {{ $option->name }}</option>
@endforeach
@endforeach
</select>
@ -85,64 +85,6 @@
</div>
</div>
<hr />
<div class="row">
<div class="col-md-12">
<h5 class="nopad">Build Parameters</h5>
<div class="well" style="margin-bottom:0">
<div class="row">
<div class="form-group col-md-3 col-xs-6">
<label class="control-label">Memory:</label>
<div class="input-group">
<input type="text" name="build_memory" class="form-control" value="{{ old('build_memory', 0) }}"/>
<span class="input-group-addon">MB</span>
</div>
</div>
<div class="form-group col-md-3 col-xs-6">
<label class="control-label">Swap:</label>
<div class="input-group">
<input type="text" name="build_swap" class="form-control" value="{{ old('build_swap', 0) }}"/>
<span class="input-group-addon">MB</span>
</div>
</div>
<div class="form-group col-md-3 col-xs-6">
<label class="control-label">CPU:</label>
<div class="input-group">
<input type="text" name="build_cpu" class="form-control" value="{{ old('build_cpu', 0) }}"/>
<span class="input-group-addon">%</span>
</div>
</div>
<div class="form-group col-md-3 col-xs-6">
<label class="control-label">IO:</label>
<div class="input-group">
<input type="text" name="build_io" class="form-control" value="{{ old('build_io', 300) }}"/>
<span class="input-group-addon">I/O</span>
</div>
</div>
<div class="form-group col-md-12">
<div>
<p class="text-muted"><small>If you would like to set limits on the build container you may do so above. Setting <code>memory</code>, <code>swap</code>, or <code>cpu</code> to <code>0</code> will allow unlimited resource utilization. IO must be in a range between <code>10</code> to <code>1000</code> and is a relative weighting to other container IO usage.</small></p>
</div>
</div>
</div>
<div class="row">
<div class="form-group col-md-12">
<label class="control-label">Build Container:</label>
<div>
<input type="text" name="build_container" class="form-control" value="{{ old('build_container', 'alpine:latest') }}"/>
<p class="text-muted"><small>Provide the docker container image that will be used to build this service pack. This container is <em>only</em> used if a build script is provided below.</small></p>
</div>
</div>
<div class="form-group col-md-12">
<label class="control-label">Build Script:</label>
<div id="build_script" style="height:200px"></div>
<textarea id="editor_contents" name="build_script" class="hidden"></textarea>
<p class="text-muted"><small>This script will be run inside the container if provided. You should use this script to download any additional dependencies or compile packages as necessary on the node. Your uploaded archive (if provided), will be available in <code>/input</code> as <code>archive.tar.gz</code> or as <code>archive.zip</code> depending on what format you uploaded as. Your completed pack should be saved as <code>package.tar.gz</code> in the <code>/output</code> directory (e.g. <code>/output/package.tar.gz</code>).</small></p>
</div>
</div>
</div>
</div>
</div>
<hr />
<div class="row">
<div class="col-md-12">
<h5 class="nopad">File Upload</h5>
@ -150,8 +92,8 @@
<div class="row">
<div class="form-group col-md-12">
<label class="control-label">Package Archive:</label>
<input name="file_upload" type="file" accept=".zip,.tar.gz, application/zip, application/gzip" />
<p class="text-muted"><small>This package file must either be a <code>.zip</code> or <code>.tar.gz</code> archive of files to use for either building or running this pack.<br /><br />If your file is larger than <code>20MB</code> we recommend uploading it using SFTP. Once you have added this pack to the system, a path will be provided where you should upload the file.
<input name="file_upload" type="file" accept=".tar.gz, application/gzip" />
<p class="text-muted"><small>This package file must be a <code>.tar.gz</code> archive of files to use for either building or running this pack.<br /><br />If your file is larger than <code>20MB</code> we recommend uploading it using SFTP. Once you have added this pack to the system, a path will be provided where you should upload the file.
This server is currently configured with the following limits: <code>upload_max_filesize={{ ini_get('upload_max_filesize') }}</code> and <code>post_max_size={{ ini_get('post_max_size') }}</code>. If your file is larger than either of those values this request will fail.</small></p>
</div>
</div>

View file

@ -12,10 +12,10 @@
<div class="col-md-12">
<label class="control-label">Associated Service Option:</label>
<select name="option" class="form-control">
@foreach($services as $service => $options)
<option disabled>{{ $service }}</option>
@foreach($options as $option)
<option value="{{ $option['id'] }}" @if((int) $for === (int) $option['id'])selected="selected"@endif>&nbsp;&nbsp; -- {{ $option['name'] }}</option>
@foreach($services as $service)
<option disabled>{{ $service->name }}</option>
@foreach($service->options as $option)
<option value="{{ $option->id }}" @if((int) request()->option === $option->id)selected="selected"@endif>&nbsp;&nbsp; -- {{ $option->name }}</option>
@endforeach
@endforeach
</select>

View file

@ -41,12 +41,12 @@
</tr>
</thead>
<tbody>
@foreach($options as $option)
@foreach($service->options as $option)
<tr>
<td><a href="{{ route('admin.services.option', [ $service->id, $option->id]) }}">{{ $option->name }}</a></td>
<td>{!! $option->description !!}</td>
<td><code>{{ $option->tag }}</code></td>
<td class="text-center">{{ $option->c_servers }}</td>
<td class="text-center">{{ $option->servers->count() }}</td>
</tr>
@endforeach
<tr>

View file

@ -39,7 +39,7 @@
<div class="col-md-6">
<fieldset>
<div class="form-group">
<label for="email" class="control-label">{{ trans('strings.email') }}</label>
<label for="email" class="control-label">Email</label>
<div>
<input type="text" name="email" value="{{ $user->email }}" class="form-control">
</div>
@ -64,7 +64,7 @@
</div>
<div class="form-group">
{!! csrf_field() !!}
<input type="submit" value="{{ trans('base.account.update_user') }}" class="btn btn-primary btn-sm">
<input type="submit" value="Update User" class="btn btn-primary btn-sm">
</div>
</fieldset>
</div>
@ -72,7 +72,7 @@
<div class="well" style="padding-bottom: 0;">
<div class="alert alert-success" style="display:none;margin-bottom:10px;" id="gen_pass"></div>
<div class="form-group">
<label for="password" class="control-label">{{ trans('strings.password') }}</label>
<label for="password" class="control-label">Password</label>
<div>
<input type="password" id="password" name="password" class="form-control">
</div>
@ -83,7 +83,7 @@
</div>
<div class="well" style="padding-bottom: 0;">
<div class="form-group">
<label for="root_admin" class="control-label">{{ trans('strings.root_administrator') }}</label>
<label for="root_admin" class="control-label">Administrator</label>
<div>
<select name="root_admin" class="form-control">
<option value="0">{{ trans('strings.no') }}</option>
@ -99,7 +99,7 @@
<div class="row">
<div class="col-md-12">
<h3>Associated Servers</h3><hr>
@if($servers)
@if($user->servers)
<table class="table table-striped table-bordered table-hover">
<thead>
<tr>
@ -112,12 +112,12 @@
</tr>
</thead>
<tbody>
@foreach($servers as $server)
@foreach($user->servers as $server)
<tr>
<td><a href="/server/{{ $server->uuidShort }}/"><i class="fa fa-tachometer"></i></a></td>
<td><code>{{ $server->uuidShort }}</code></td>
<td><a href="/admin/servers/view/{{ $server->id }}">{{ $server->name }}</a></td>
<td>{{ $server->nodeName }}</td>
<td>{{ $server->node->name }}</td>
<td><code>{{ $server->username }}</code></td>
<td class="centered">@if($server->suspended === 0)<span class="label muted muted-hover label-success">Active</span>@else<span class="label label-warning">Suspended</span>@endif</td>
</td>
@ -127,7 +127,7 @@
@else
<div class="alert alert-info">There are no servers associated with this account.</div>
@endif
<a href="/admin/servers/new?email={{ $user->email }}"><button type="button" class="btn btn-success btn-sm">{{ trans('server.index.add_new') }}</button></a>
<a href="/admin/servers/new?email={{ $user->email }}"><button type="button" class="btn btn-success btn-sm">Add New Server</button></a>
</div>
</div>
<div class="row">

View file

@ -1,31 +0,0 @@
{{-- Copyright (c) 2015 - 2017 Dane Everitt <dane@daneeveritt.com> --}}
{{-- Permission is hereby granted, free of charge, to any person obtaining a copy --}}
{{-- of this software and associated documentation files (the "Software"), to deal --}}
{{-- in the Software without restriction, including without limitation the rights --}}
{{-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell --}}
{{-- copies of the Software, and to permit persons to whom the Software is --}}
{{-- furnished to do so, subject to the following conditions: --}}
{{-- The above copyright notice and this permission notice shall be included in all --}}
{{-- copies or substantial portions of the Software. --}}
{{-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR --}}
{{-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, --}}
{{-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE --}}
{{-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER --}}
{{-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, --}}
{{-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE --}}
{{-- SOFTWARE. --}}
<html>
<head>
<title>Pterodactyl - New Account</title>
</head>
<body>
<center><h1>Pterodactyl - Account Created</h1></center>
<p>You are recieving this email because an account has been created for you on Pterodactyl Panel.</p>
<p>Login: <a href="{{ $login }}">{{ $login }}</a></p>
<p>Email: {{ $email }}</p>
<p>Forgot your password? <a href="{{ $forgot }}">{{ $forgot }}</a></p>
</body>
</html>

View file

@ -1,32 +0,0 @@
{{-- Copyright (c) 2015 - 2017 Dane Everitt <dane@daneeveritt.com> --}}
{{-- Permission is hereby granted, free of charge, to any person obtaining a copy --}}
{{-- of this software and associated documentation files (the "Software"), to deal --}}
{{-- in the Software without restriction, including without limitation the rights --}}
{{-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell --}}
{{-- copies of the Software, and to permit persons to whom the Software is --}}
{{-- furnished to do so, subject to the following conditions: --}}
{{-- The above copyright notice and this permission notice shall be included in all --}}
{{-- copies or substantial portions of the Software. --}}
{{-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR --}}
{{-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, --}}
{{-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE --}}
{{-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER --}}
{{-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, --}}
{{-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE --}}
{{-- SOFTWARE. --}}
<html>
<head>
<title>Pterodactyl - Admin Reset Password</title>
</head>
<body>
<center><h1>Pterodactyl - Admin Reset Password</h1></center>
<p>Hello there! You are receiving this email because an admin has reset the password on your Pterodactyl account.</p>
<p><strong>Login:</strong> <a href="{{ config('app.url') }}/auth/login">{{ config('app.url') }}/auth/login</a><br>
<strong>Email:</strong> {{ $user->email }}<br>
<strong>Password:</strong> {{ $password }}</p>
<p>Thanks,<br>Pterodactyl</p>
</body>
</html>

View file

@ -19,4 +19,4 @@ if (! empty($outroLines)) {
}
echo 'Regards,', "\n";
echo Settings::get('company'), "\n";
echo Settings::get('company', 'Pterodactyl Panel'), "\n";

View file

@ -71,7 +71,7 @@ $style = [
<tr>
<td style="{{ $style['email-masthead'] }}">
<a style="{{ $fontFamily }} {{ $style['email-masthead_name'] }}" href="{{ url('/') }}" target="_blank">
{{ Settings::get('company') }}
{{ Settings::get('company', 'Pterodactyl Panel') }}
</a>
</td>
</tr>
@ -176,7 +176,7 @@ $style = [
<td style="{{ $fontFamily }} {{ $style['email-footer_cell'] }}">
<p style="{{ $style['paragraph-sub'] }}">
&copy; {{ date('Y') }}
<a style="{{ $style['anchor'] }}" href="{{ url('/') }}" target="_blank">{{ Settings::get('company') }}</a>.
<a style="{{ $style['anchor'] }}" href="{{ url('/') }}" target="_blank">{{ Settings::get('company', 'Pterodactyl Panel') }}</a>.
All rights reserved.
</p>
</td>