Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yaoai-video
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
姚珂
yaoai-video
Commits
347882ac
Commit
347882ac
authored
Jun 02, 2026
by
yaoke.yk
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
运营docker映射端口改动
parent
7a80307a
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
40 additions
and
6 deletions
+40
-6
docker-compose.yml
docker-compose.yml
+12
-0
start-prod-local.ps1
start-prod-local.ps1
+28
-6
No files found.
docker-compose.yml
View file @
347882ac
...
...
@@ -80,6 +80,18 @@ services:
-
"
${FRONTEND_PORT:-3000}:80"
restart
:
unless-stopped
admin-web
:
build
:
context
:
./yaoai-admin-web
dockerfile
:
Dockerfile
environment
:
ADMIN_API_UPSTREAM
:
http://backend:8080
depends_on
:
-
backend
ports
:
-
"
${ADMIN_FRONTEND_PORT:-3001}:80"
restart
:
unless-stopped
volumes
:
mysql-data
:
redis-data
:
start-prod-local.ps1
View file @
347882ac
...
...
@@ -11,17 +11,39 @@ try {
Write-Host
"[prod-local] .env not found, copied from .env.example"
}
$config
=
@
{}
Get-Content
$envFile
|
ForEach
-Object
{
$line
=
$_
.Trim
()
if
(
$line
-and -not
$line
.StartsWith
(
"#"
)
-and
$line
.Contains
(
"="
))
{
$index
=
$line
.IndexOf
(
"="
)
$key
=
$line
.Substring
(
0,
$index
)
.Trim
()
$value
=
$line
.Substring
(
$index
+ 1
)
.Trim
()
$config
[
$key
]
=
$value
}
}
function
Get-ConfigValue
(
$key
,
$fallback
)
{
if
(
$config
.ContainsKey
(
$key
)
-and
$config
[
$key
])
{
return
$config
[
$key
]
}
return
$fallback
}
$mysqlPort
=
Get-ConfigValue
"MYSQL_PORT"
"13306"
$redisPort
=
Get-ConfigValue
"REDIS_PORT"
"16379"
$frontendPort
=
Get-ConfigValue
"FRONTEND_PORT"
"3000"
$adminFrontendPort
=
Get-ConfigValue
"ADMIN_FRONTEND_PORT"
"3001"
$backendPort
=
Get-ConfigValue
"BACKEND_PORT"
"8080"
Write-Host
"[prod-local] starting root docker-compose.yml ..."
docker compose up -d --build
Write-Host
""
Write-Host
"[prod-local] stable local deployment environment"
Write-Host
" mysql : localhost:
23306
"
Write-Host
" redis : localhost:
26379
"
Write-Host
" frontend : http://localhost:
3000
"
Write-Host
" admin-web : http://localhost:
3001
"
Write-Host
" backend : http://localhost:
28081
"
Write-Host
" swagger : http://localhost:
28081
/swagger-ui/index.html"
Write-Host
" mysql : localhost:
$mysqlPort
"
Write-Host
" redis : localhost:
$redisPort
"
Write-Host
" frontend : http://localhost:
$frontendPort
"
Write-Host
" admin-web : http://localhost:
$adminFrontendPort
"
Write-Host
" backend : http://localhost:
$backendPort
"
Write-Host
" swagger : http://localhost:
$backendPort
/swagger-ui/index.html"
Write-Host
""
Write-Host
"[prod-local] if you need different ports, edit .env before running this script."
Write-Host
"[prod-local] do not run 'docker compose down -v' unless you really want to delete prod-local data."
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment