remove faker from prod
This commit is contained in:
parent
7377f80bdd
commit
4ebae8dcf6
@ -10,8 +10,7 @@ class EmptyProject extends Component
|
||||
public function createEmptyProject()
|
||||
{
|
||||
$project = Project::create([
|
||||
'name' => fake()->company(),
|
||||
'description' => fake()->sentence(),
|
||||
'name' => generateRandomName(),
|
||||
'team_id' => session('currentTeam')->id,
|
||||
]);
|
||||
return redirect()->route('project.environments', ['project_uuid' => $project->uuid, 'environment_name' => 'production']);
|
||||
|
@ -79,8 +79,7 @@ class PublicGitRepository extends Component
|
||||
|
||||
if ($this->type === 'project') {
|
||||
$project = Project::create([
|
||||
'name' => fake()->company(),
|
||||
'description' => fake()->sentence(),
|
||||
'name' => generateRandomName(),
|
||||
'team_id' => session('currentTeam')->id,
|
||||
]);
|
||||
$environment = $project->environments->first();
|
||||
@ -89,7 +88,7 @@ class PublicGitRepository extends Component
|
||||
$environment = $project->environments->where('name', $this->parameters['environment_name'])->firstOrFail();
|
||||
}
|
||||
$application_init = [
|
||||
'name' => fake()->words(2, true),
|
||||
'name' => generateRandomName(),
|
||||
'git_repository' => $git_repository,
|
||||
'git_branch' => $git_branch,
|
||||
'build_pack' => 'nixpacks',
|
||||
|
@ -43,7 +43,7 @@ class ByIp extends Component
|
||||
public function submit()
|
||||
{
|
||||
$server = Server::create([
|
||||
'name' => fake()->company,
|
||||
'name' => generateRandomName(),
|
||||
'ip' => $this->ip,
|
||||
'user' => $this->user,
|
||||
'port' => $this->port,
|
||||
|
@ -143,3 +143,14 @@ if (!function_exists('getLatestVersionOfCoolify')) {
|
||||
return data_get($versions, 'coolify.v4.version');
|
||||
}
|
||||
}
|
||||
if (!function_exists('generateRandomName')) {
|
||||
function generateRandomName()
|
||||
{
|
||||
$generator = new \Nubs\RandomNameGenerator\All(
|
||||
[
|
||||
new \Nubs\RandomNameGenerator\Vgng()
|
||||
]
|
||||
);
|
||||
return $generator->getName();
|
||||
}
|
||||
}
|
||||
|
@ -13,6 +13,7 @@
|
||||
"laravel/tinker": "^v2.8.1",
|
||||
"lcobucci/jwt": "^5.0.0",
|
||||
"livewire/livewire": "^v2.12.3",
|
||||
"nubs/random-name-generator": "^2.2",
|
||||
"spatie/laravel-activitylog": "^4.7.3",
|
||||
"spatie/laravel-data": "^3.4.3",
|
||||
"spatie/laravel-ray": "^1.32.4",
|
||||
|
55
composer.lock
generated
55
composer.lock
generated
@ -4,7 +4,7 @@
|
||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "fe67e3799aed430897c4ad82f323abe1",
|
||||
"content-hash": "edc1042455661505e65373a55fed9b81",
|
||||
"packages": [
|
||||
{
|
||||
"name": "bacon/bacon-qr-code",
|
||||
@ -2469,6 +2469,59 @@
|
||||
},
|
||||
"time": "2023-03-05T19:49:14+00:00"
|
||||
},
|
||||
{
|
||||
"name": "nubs/random-name-generator",
|
||||
"version": "v2.2.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/nubs/random-name-generator.git",
|
||||
"reference": "50abf24519badc5795a43c831f1d2a1faa45cb77"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/nubs/random-name-generator/zipball/50abf24519badc5795a43c831f1d2a1faa45cb77",
|
||||
"reference": "50abf24519badc5795a43c831f1d2a1faa45cb77",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "~5.6 || ~7.0 || ~8.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"cinam/randomizer": ">=1.1.1,<2.0",
|
||||
"php-coveralls/php-coveralls": "~2.4",
|
||||
"phpunit/phpunit": "^5.0 || ^6.5 || ^7.0 || ^9.0",
|
||||
"squizlabs/php_codesniffer": "~2.3"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Nubs\\RandomNameGenerator\\": "src"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Spencer Rinehart",
|
||||
"email": "anubis@overthemonkey.com",
|
||||
"role": "Developer"
|
||||
}
|
||||
],
|
||||
"description": "A library to create interesting, sometimes entertaining, random names.",
|
||||
"keywords": [
|
||||
"alliteration",
|
||||
"generator",
|
||||
"random",
|
||||
"video game"
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/nubs/random-name-generator/issues",
|
||||
"source": "https://github.com/nubs/random-name-generator/tree/v2.2.0"
|
||||
},
|
||||
"time": "2021-01-12T13:46:08+00:00"
|
||||
},
|
||||
{
|
||||
"name": "nunomaduro/termwind",
|
||||
"version": "v1.15.1",
|
||||
|
Loading…
x
Reference in New Issue
Block a user