generated from CC/VMServiceTemplate
mod workflow && docker copy
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
name: Deploy VM and App
|
||||
|
||||
on:
|
||||
push:
|
||||
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
tfvars_file:
|
||||
@@ -17,16 +15,6 @@ on:
|
||||
jobs:
|
||||
terraform-ansible-deploy:
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
PROXMOX_VE_API_TOKEN: https://api.staging.example.com
|
||||
PROXMOX_VE_ENDPOINT: true
|
||||
GITEA_BASE_URL: https://api.staging.example.com
|
||||
GITEA_TOKEN: true
|
||||
AWS_ACCESS_KEY_ID: https://api.staging.example.com
|
||||
AWS_SECRET_ACCESS_KEY: true
|
||||
AWS_REGION: garage
|
||||
TF_VAR_vm_ssh_userkey: ${{ secrets.VM_USER_SSHKEY }}
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
- hosts: all
|
||||
become: true
|
||||
vars:
|
||||
folder_name: n8n
|
||||
folder_name: music
|
||||
|
||||
roles:
|
||||
- role: docker
|
||||
|
||||
@@ -1,17 +1,12 @@
|
||||
---
|
||||
# Copy directory recursively to remote host
|
||||
|
||||
- name: Copy project directory to remote
|
||||
ansible.builtin.synchronize:
|
||||
src: ../compose/{{ folder_name }}
|
||||
dest: /home/cloud/
|
||||
ansible.posix.synchronize:
|
||||
src: "../../compose/{{ folder_name }}/"
|
||||
dest: "/home/cloud/{{ folder_name }}/"
|
||||
mode: push
|
||||
|
||||
|
||||
- name: Start Compose stack
|
||||
community.docker.docker_compose_v2:
|
||||
project_src: /home/cloud/{{ folder_name }}
|
||||
project_src: "/home/cloud/{{ folder_name }}"
|
||||
build: always
|
||||
pull: always
|
||||
state: present
|
||||
|
||||
|
||||
Reference in New Issue
Block a user