auto_build.sh
This commit is contained in:
parent
315d7f9193
commit
145ba879bf
11
auto_build.sh
Normal file
11
auto_build.sh
Normal file
@ -0,0 +1,11 @@
|
||||
#!/bin/bash
|
||||
|
||||
GIT_WORK_TREE=/www/wwwroot/fs.book.wandoubaba.com
|
||||
|
||||
cd $GIT_WORK_TREE
|
||||
|
||||
git pull origin master
|
||||
|
||||
yarn install
|
||||
|
||||
yarn build
|
@ -28,11 +28,11 @@ $worker->onMessage = function (TcpConnection $connection, Request $request) {
|
||||
$clone_url = isset($repository['clone_url']) ? $repository['clone_url'] : null;
|
||||
if ($git_url === $ssh_url || $git_url === $clone_url) {
|
||||
chdir($work_dir);
|
||||
shell_exec("git fetch origin $branch");
|
||||
shell_exec("git reset --hard FETCH_HEAD");
|
||||
shell_exec("sh auto_build.sh");
|
||||
// shell_exec("git reset --hard FETCH_HEAD");
|
||||
|
||||
shell_exec("yarn install");
|
||||
shell_exec("yarn build");
|
||||
// shell_exec("yarn install");
|
||||
// shell_exec("yarn build");
|
||||
|
||||
$connection->send("Deployment finished\n");
|
||||
$connection->close();
|
||||
|
Loading…
Reference in New Issue
Block a user