This commit is contained in:
Andras Bacsai 2023-06-12 14:47:42 +02:00
parent 3da58ed2b8
commit 2ae67b8ca9
5 changed files with 12 additions and 11 deletions

View File

@ -1,3 +1,4 @@
SELF_HOSTED=true
############################################################################################################
# Development Environment
@ -18,7 +19,6 @@ APP_SERVICE=php
APP_ENV=local
APP_KEY=
APP_DEBUG=true
APP_URL=http://localhost
APP_PORT=8000
MAIL_MAILER=smtp

View File

@ -1,5 +1,4 @@
COOLIFY_DEFAULT_PROXY=traefik
COOLIFY_DEFAULT_NETWORK=coolify
SELF_HOSTED=true
SENTRY_LARAVEL_DSN=https://fc21c062604d4526a4a9f263a0addeac@o1082494.ingest.sentry.io/4504672605372416
SENTRY_TRACES_SAMPLE_RATE=0.2
@ -9,8 +8,7 @@ APP_SERVICE=php
APP_ENV=production
APP_KEY=
APP_DEBUG=false
APP_URL=http://localhost
APP_PORT=3000
APP_PORT=8000
SESSION_DRIVER=database

View File

@ -1,6 +1,7 @@
<?php
return [
'self_hosted' => env('SELF_HOSTED', true),
'mux_enabled' => env('MUX_ENABLED', true),
'dev_webhook' => env('SERVEO_URL'),
'base_config_path' => env('BASE_CONFIG_PATH', '/data/coolify'),

View File

@ -89,12 +89,10 @@ public function run(): void
'team_id' => 0,
'private_key_id' => 0
];
if (env('COOLIFY_DEFAULT_PROXY') == 'traefik') {
$server_details['extra_attributes'] = ServerMetadata::from([
'proxy_type' => ProxyTypes::TRAEFIK_V2->value,
'proxy_status' => ProxyStatus::EXITED->value
]);
}
$server_details['extra_attributes'] = ServerMetadata::from([
'proxy_type' => ProxyTypes::TRAEFIK_V2->value,
'proxy_status' => ProxyStatus::EXITED->value
]);
$server = Server::create($server_details);
$server->settings->is_validated = true;
$server->settings->save();

View File

@ -39,6 +39,7 @@ curl -fsSL $CDN/docker-compose.prod.yml -o /data/coolify/source/docker-compose.p
curl -fsSL $CDN/.env.production -o /data/coolify/source/.env.production
curl -fsSL $CDN/upgrade.sh -o /data/coolify/source/upgrade.sh
# Copy .env.example if .env does not exist
if [ ! -f /data/coolify/source/.env ]; then
cp /data/coolify/source/.env.production /data/coolify/source/.env
@ -47,6 +48,9 @@ if [ ! -f /data/coolify/source/.env ]; then
sed -i "s|REDIS_PASSWORD=.*|REDIS_PASSWORD=$(openssl rand -base64 32)|g" /data/coolify/source/.env
fi
# Merge .env and .env.production. New values will be added to .env
sort -u -t '=' -k 1,1 /data/coolify/source/.env.production /data/coolify/source/.env | sed '/^$/d' > /data/coolify/source/.env
# Generate an ssh key (ed25519) at /data/coolify/ssh/keys/id.root@host.docker.internal
if [ ! -f /data/coolify/ssh/keys/id.root@host.docker.internal ]; then
ssh-keygen -t ed25519 -f /data/coolify/ssh/keys/id.root@host.docker.internal -q -N "" -C root@coolify