v3 #1

Open
thienvv wants to merge 69 commits from v3 into main
2 changed files with 12 additions and 14 deletions
Showing only changes of commit ad216b4fef - Show all commits
+1 -1
View File
@@ -1,4 +1,4 @@
- name: Deploy Backend for Project Acp, Portal
- name: Deploy Backend for Project Portal
hosts: "{{ deploy_env }}-{{project_name}}-backend"
vars:
portal_name: "{{ portal_name }}"
+11 -13
View File
@@ -24,19 +24,17 @@
debug:
var: artifact_name
- name: Set environment variable for IIS App Pool
hosts: windows_servers
tasks:
- name: Thiết lập ASPNETCORE_ENVIRONMENT cho App Pool
win_shell: |
$appPoolName = "{{ iis_app_pool }}"
$envVarName = "ASPNETCORE_ENVIRONMENT"
$envVarValue = "{{ aspnetcore_environtment }}"
$appPool = Get-Item "IIS:\AppPools\$appPoolName"
$appPool.EnvironmentVariables[$envVarName] = $envVarValue
$appPool | Set-Item
args:
executable: powershell.exe
- name: Set registry key for IIS App Pool environment variable
win_regedit:
path: "HKLM:\\SYSTEM\\CurrentControlSet\\Services\\W3SVC\\AppPools\\{{ iis_app_pool }}\\Environment"
name: "TEST_ENV"
type: string
data: "{{ aspnetcore_environtment }}"
- name: Khởi động lại App Pool (hoặc IIS) để áp dụng
win_iis_webapppool:
name: "{{ iis_app_pool }}"
state: restarted
#Lấy đường dẫn vật lý của iis site
- name: Get the physical path of the current IIS site