-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstart.ps1
More file actions
16 lines (12 loc) · 639 Bytes
/
start.ps1
File metadata and controls
16 lines (12 loc) · 639 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
Write-Host "Starting Docker container to run build server"
$SITE_NAME = Get-Content .\CNAME -Raw
$SITE_NAME = $SITE_NAME -replace "[.\n\r]", "-"
$CONATINER_NAME = "build-$SITE_NAME"
$PORT = Get-Content .\dev.port -Raw
$PORT = $PORT -replace "[.\n\r]", ""
$PORT_LIVERELOAD = Get-Content .\dev-livereload.port -Raw
$PORT_LIVERELOAD = $PORT_LIVERELOAD -replace "[.\n\r]", ""
#start docker build container
docker run --name $CONATINER_NAME -d -p ${PORT}:${PORT} -p ${PORT_LIVERELOAD}:${PORT_LIVERELOAD} -v ${PWD}:/build/source:rw aemdesign/centos-java-buildpack sleep inf
#connect to container
docker exec -it $CONATINER_NAME bash --login