File tree 3 files changed +16
-2
lines changed
3 files changed +16
-2
lines changed Original file line number Diff line number Diff line change @@ -215,6 +215,12 @@ public function asNodeTasks(): array
215
215
216
216
if (! empty ($ caddyHandlers )) {
217
217
$ caddy = [
218
+ 'admin ' => [
219
+ 'enforce_origin ' => true ,
220
+ 'origins ' => [
221
+ 'custom-uuid-origin ' ,
222
+ ],
223
+ ],
218
224
'apps ' => [
219
225
'http ' => [
220
226
'servers ' => (object ) [],
Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ protected static function booted()
80
80
81
81
protected function generateUniqueSlug ($ id )
82
82
{
83
- $ slug = Str::slug ($ this ->name );
83
+ $ slug = Str::slug ($ this ->name , ' _ ' );
84
84
$ vocabulary = config ('ptah.services.slug.vocabulary ' );
85
85
$ adjectives = config ('ptah.services.slug.adjectives ' );
86
86
Original file line number Diff line number Diff line change @@ -87,13 +87,21 @@ if [ -z "$SKIP_CORE_INSTALL" ]; then
87
87
header " Install System Packages"
88
88
89
89
$PKG_UPDATE_REGISTRIES
90
- $PKG_INSTALL sudo curl unzip ca-certificates apache2-utils
90
+ $PKG_INSTALL sudo curl unzip ca-certificates apache2-utils netfilter-persistent
91
91
92
92
header " Install Docker"
93
93
help_text " installation script provided by Docker and available at https://get.docker.com/"
94
94
95
95
curl -fsSL https://get.docker.com/ | sh
96
96
97
+ header " Configure Docker"
98
+ help_text " Adding Caddy admin port to iptables"
99
+
100
+ iptables -I DOCKER-USER -p tcp -s 127.0.0.1 --dport 2019 -j ACCEPT
101
+ iptables -I DOCKER-USER -p tcp --dport 2019 -j REJECT --reject-with tcp-reset
102
+
103
+ netfilter-persistent save
104
+
97
105
rm -f /tmp/ptah-agent
98
106
99
107
curl -L https://github.com/ptah-sh/ptah-agent/releases/latest/download/ptah-agent-linux-x86_64.bin -o /tmp/ptah-agent
You can’t perform that action at this time.
0 commit comments