master
omidshj 2024-08-26 15:19:35 +03:30
parent 14dfbf545e
commit 21c6706914
1 changed files with 9 additions and 5 deletions

View File

@ -1,10 +1,14 @@
---
- name: deploy 3d
- name: Deploy 3d
hosts: all
tasks:
- name: Go to the 3d directory
command: chdir=/var/www/nuxt/3d git pull origin master
- name: Go to the 3d directory and pull the latest code
shell: git pull origin master
args:
chdir: /var/www/nuxt/3d
register: git_result
- name: build source
command: chdir=/var/www/nuxt/3d docker run -w /srv -v $(pwd):/srv -u $(id -u ${USER}):$(id -g ${USER}) --rm node:20.8 npm run buil
- name: Build source with Docker
shell: docker run -w /srv -v $(pwd):/srv -u $(id -u):$(id -g) --rm node:20.8 npm run build
args:
chdir: /var/www/nuxt/3d