Skip to content

Commit 21ffa08

Browse files
committed
Merge branch 'develop' into feature/vuejs
2 parents cc7f7d7 + f6d0147 commit 21ffa08

File tree

54 files changed

+407
-243
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+407
-243
lines changed

.dev/docker/default_ssl.conf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ server {
1111
listen 443 ssl http2;
1212
server_name <domain>;
1313

14-
root /var/www/pterodactyl/public;
14+
root /app/public;
1515
index index.php;
1616

1717
access_log /var/log/nginx/pterodactyl.app-access.log;
@@ -49,7 +49,7 @@ server {
4949

5050
location ~ \.php$ {
5151
fastcgi_split_path_info ^(.+\.php)(/.+)$;
52-
fastcgi_pass unix:/run/php/pterodactyl.sock;
52+
fastcgi_pass unix:/var/run/php/php-fpm7.2.sock;
5353
fastcgi_index index.php;
5454
include fastcgi_params;
5555
fastcgi_param PHP_VALUE "upload_max_filesize = 100M \n post_max_size=100M";

.dev/docker/entrypoint.sh

Lines changed: 31 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,26 +3,50 @@
33

44
cd /app
55

6+
mkdir -p /var/log/panel/logs/ /var/log/supervisord/ /var/log/nginx/ /var/log/php7/ \
7+
&& rmdir /app/storage/logs/ \
8+
&& chmod 777 /var/log/panel/logs/ \
9+
&& ln -s /var/log/panel/logs/ /app/storage/
10+
611
## check for .env file and generate app keys if missing
712
if [ -f /app/var/.env ]; then
8-
echo "external vars exist"
13+
echo "external vars exist."
914
rm /app/.env
1015

1116
ln -s /app/var/.env /app/
1217
else
13-
echo "external vars don't exist"
18+
echo "external vars don't exist."
1419
rm /app/.env
1520
touch /app/var/.env
1621

1722
## manually generate a key because key generate --force fails
18-
echo -e "Generating key"
23+
echo -e "Generating key."
1924
APP_KEY=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)
2025
echo -e "Generated app key: $APP_KEY"
2126
echo -e "APP_KEY=$APP_KEY" > /app/var/.env
2227

2328
ln -s /app/var/.env /app/
2429
fi
2530

31+
echo "Checking if https is required."
32+
if [ -f /etc/nginx/conf.d/default.conf ]; then
33+
echo "Using nginx config already in place."
34+
else
35+
echo "Checking if letsencrypt email is set."
36+
if [ -z $LE_EMAIL ]; then
37+
echo "No letsencrypt email is set Failing to http."
38+
cp .dev/docker/default.conf /etc/nginx/conf.d/default.conf
39+
40+
else
41+
echo "writing ssl config"
42+
cp .dev/docker/default_ssl.conf /etc/nginx/conf.d/default.conf
43+
echo "updating ssl config for domain"
44+
sed -i "s|<domain>|$(echo $APP_URL | sed 's~http[s]*://~~g')|g" /etc/nginx/conf.d/default.conf
45+
echo "generating certs"
46+
certbot certonly -d $(echo $APP_URL | sed 's~http[s]*://~~g') --standalone -m $LE_EMAIL --agree-tos -n
47+
fi
48+
fi
49+
2650
## check for DB up before starting the panel
2751
echo "Checking database status."
2852
until nc -z -v -w30 $DB_HOST 3306
@@ -34,13 +58,13 @@ do
3458
done
3559

3660
## make sure the db is set up
37-
echo -e "Migrating and Seeding DB"
61+
echo -e "Migrating and Seeding D.B"
3862
php artisan migrate --force
3963
php artisan db:seed --force
4064

4165
## start cronjobs for the queue
42-
echo -e "Starting cron jobs"
43-
crond
66+
echo -e "Starting cron jobs."
67+
crond -L /var/log/crond -l 5
4468

45-
echo -e "Starting supervisord"
69+
echo -e "Starting supervisord."
4670
exec "$@"

.phraseapp.yml

Lines changed: 0 additions & 29 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,34 @@ This file is a running track of new features and fixes to each version of the pa
33

44
This project follows [Semantic Versioning](http://semver.org) guidelines.
55

6+
## v0.7.12 (Derelict Dermodactylus)
7+
### Fixed
8+
* Fixes an issue with the locations API endpoint referencing an invalid namespace.
9+
* Fixes the `store()` function on the locations API not working due to an incorrect return typehint.
10+
* Fixes daemon secrets not being able to be reset on a Node.
11+
12+
### Updated
13+
* Upgraded core to use Laravel `5.7.14`.
14+
15+
### Added
16+
* Added support for opening and editing Python files through the web editor.
17+
18+
## v0.7.11 (Derelict Dermodactylus)
19+
### Fixed
20+
* Fixes an issue with certain systems not handling an API folder that was named `API` but referenced as `Api` in the namespace.
21+
* TS3 egg updated to use CLI arguments correctly and have a more minimalistic installation script.
22+
* Terminal was not properly displaying longer lines leading to some visual inconsistency.
23+
* Assorted translation updates.
24+
* Pagination for server listing now properly respects configuration setting.
25+
* Client API now properly respects permissions that are set and allows subusers to access their assigned servers.
26+
27+
### Changed
28+
* Removed PhraseApp integration from Panel code as it is no longer used.
29+
* SFTP login endpoint now returns the permissions for that user rather than requiring additional queries to get that data.
30+
31+
### Added
32+
* You can now test your mail settings from the Admin CP without waiting to see if things are working correctly.
33+
634
## v0.7.10 (Derelict Dermodactylus)
735
### Fixed
836
* Scheduled tasks triggered manually no longer improperly change the `next_run_at` time and do not run twice in a row anymore.

Dockerfile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ FROM alpine:3.8
22

33
WORKDIR /app
44

5-
RUN apk add --no-cache --update ca-certificates certbot nginx dcron curl tini php7 php7-bcmath php7-common php7-dom php7-fpm php7-gd php7-mbstring php7-openssl php7-zip php7-pdo php7-phar php7-json php7-pdo_mysql php7-session php7-ctype php7-tokenizer php7-zlib php7-simplexml supervisor \
5+
RUN apk add --no-cache --update ca-certificates certbot nginx dcron curl tini php7 php7-bcmath php7-common php7-dom php7-fpm php7-gd php7-mbstring php7-openssl php7-zip php7-pdo php7-phar php7-json php7-pdo_mysql php7-session php7-ctype php7-tokenizer php7-zlib php7-simplexml php7-fileinfo supervisor \
66
&& curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
77

88
COPY . ./
@@ -15,9 +15,9 @@ RUN cp .env.example .env \
1515
RUN cp .dev/docker/default.conf /etc/nginx/conf.d/default.conf \
1616
&& cp .dev/docker/www.conf /etc/php7/php-fpm.d/www.conf \
1717
&& cat .dev/docker/supervisord.conf > /etc/supervisord.conf \
18-
&& echo "* * * * * /usr/bin/php /app/pterodactyl/artisan schedule:run >> /dev/null 2>&1" >> /var/spool/cron/crontabs/root \
19-
&& mkdir -p /var/run/php /var/run/nginx \
20-
&& mkdir -p /var/log/supervisord/
18+
&& echo "* * * * * /usr/bin/php /app/artisan schedule:run >> /dev/null 2>&1" >> /var/spool/cron/crontabs/root \
19+
&& sed -i s/ssl_session_cache/#ssl_session_cache/g /etc/nginx/nginx.conf \
20+
&& mkdir -p /var/run/php /var/run/nginx
2121

2222
EXPOSE 80 443
2323

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,7 @@ In addition to our standard nest of supported games, our community is constantly
4141
* Discord ATLBot
4242

4343
## Credits
44-
A huge thank you to [PhraseApp](https://phraseapp.com) who provide us the software to help translate this project. This software would not be possible
45-
without the work of other open-source authors who provide tools such as:
44+
This software would not be possible without the work of other open-source authors who provide tools such as:
4645

4746
[Ace Editor](https://ace.c9.io), [AdminLTE](https://almsaeedstudio.com), [Animate.css](http://daneden.github.io/animate.css/), [AnsiUp](https://github.com/drudru/ansi_up), [Async.js](https://github.com/caolan/async),
4847
[Bootstrap](http://getbootstrap.com), [Bootstrap Notify](http://bootstrap-notify.remabledesigns.com), [Chart.js](http://www.chartjs.org), [FontAwesome](http://fontawesome.io),

app/Console/Commands/Environment/AppSettingsCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ public function handle()
132132
);
133133

134134
$selected = $this->config->get('queue.default', 'redis');
135-
$this->variables['QUEUE_DRIVER'] = $this->option('queue') ?? $this->choice(
135+
$this->variables['QUEUE_CONNECTION'] = $this->option('queue') ?? $this->choice(
136136
trans('command/messages.environment.app.queue_driver'),
137137
self::ALLOWED_QUEUE_DRIVERS,
138138
array_key_exists($selected, self::ALLOWED_QUEUE_DRIVERS) ? $selected : null

app/Contracts/Repository/ServerRepositoryInterface.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,10 +103,10 @@ public function getDaemonServiceData(Server $server, bool $refresh = false): arr
103103
*
104104
* @param \Pterodactyl\Models\User $user
105105
* @param int $level
106-
* @param bool $paginate
106+
* @param bool|int $paginate
107107
* @return \Illuminate\Pagination\LengthAwarePaginator|\Illuminate\Database\Eloquent\Collection
108108
*/
109-
public function filterUserAccessServers(User $user, int $level, bool $paginate = true);
109+
public function filterUserAccessServers(User $user, int $level, $paginate = 25);
110110

111111
/**
112112
* Return a server by UUID.

app/Extensions/PhraseAppTranslator.php

Lines changed: 0 additions & 31 deletions
This file was deleted.

app/Http/Controllers/Admin/NodesController.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ public function viewServers($node)
263263
*/
264264
public function updateSettings(NodeFormRequest $request, Node $node)
265265
{
266-
$this->updateService->handle($node, $request->normalize());
266+
$this->updateService->handle($node, $request->normalize(), $request->input('reset_secret') === 'on');
267267
$this->alert->success(trans('admin/node.notices.node_updated'))->flash();
268268

269269
return redirect()->route('admin.nodes.view.settings', $node->id)->withInput();
@@ -289,7 +289,7 @@ public function allocationRemoveSingle(int $node, Allocation $allocation): Respo
289289
* Removes multiple individual allocations from a node.
290290
*
291291
* @param \Illuminate\Http\Request $request
292-
* @param int $node
292+
* @param int $node
293293
* @return \Illuminate\Http\Response
294294
*
295295
* @throws \Pterodactyl\Exceptions\Service\Allocation\ServerUsingAllocationException

0 commit comments

Comments
 (0)