Implemented shallow cloning for git

This commit is contained in:
2025-12-04 23:50:24 +01:00
parent 0cf6674ab5
commit 9fb372be52
5 changed files with 19 additions and 15 deletions

View File

@@ -5,9 +5,10 @@
- name: pull ssh repository from {{desk_ssh_repository}}
git:
repo: "{{desk_ssh_repository}}"
dest: "$HOME/.ssh"
update: yes
repo: "{{desk_ssh_repository}}"
dest: "$HOME/.ssh"
update: yes
depth: 1
register: git_result
ignore_errors: true
become: false

View File

@@ -32,10 +32,11 @@
become: true
become_user: "{{ AUR_BUILDER_USER }}"
git:
repo: https://aur.archlinux.org/yay.git
dest: "/home/{{ AUR_BUILDER_USER }}/yay"
clone: yes
repo: https://aur.archlinux.org/yay.git
dest: "/home/{{ AUR_BUILDER_USER }}/yay"
clone: yes
update: yes
depth: 1
- name: Build and install yay
become: true

View File

@@ -4,7 +4,7 @@
- name: "Install '{{ package_name }}' via Kevin's Package Manager (pkgmgr)"
ansible.builtin.shell: |
source ~/.venvs/pkgmgr/bin/activate
pkgmgr update {{ package_name }} --dependencies --clone-mode https
pkgmgr update {{ package_name }} --dependencies --clone-mode shallow
args:
executable: /bin/bash
notify: "{{ package_notify | default(omit,true) }}"

View File

@@ -29,10 +29,11 @@
- name: Clone Kevin's Package Manager repository
git:
repo: "{{ PKGMGR_REPO_URL }}"
dest: "{{ PKGMGR_INSTALL_PATH }}"
version: "HEAD"
force: yes
repo: "{{ PKGMGR_REPO_URL }}"
dest: "{{ PKGMGR_INSTALL_PATH }}"
version: "HEAD"
force: yes
depth: 1
become: true
- name: create config.yaml

View File

@@ -13,11 +13,12 @@
- name: pull docker repository
git:
repo: "{{ DISCOURSE_REPOSITORY_URL }}"
dest: "{{ DISCOURSE_REPOSITORY_DIR }}"
repo: "{{ DISCOURSE_REPOSITORY_URL }}"
dest: "{{ DISCOURSE_REPOSITORY_DIR }}"
update: yes
notify: recreate discourse
become: true
depth: 1
notify: recreate discourse
become: true
ignore_errors: true
- name: set chmod 700 for '{{ DISCOURSE_CONTAINERS_DIR }}'