Skip to content

Commit

Permalink
feat: workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
maskudo committed Feb 3, 2024
1 parent b3758c8 commit 4e9bc77
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 5 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/playbook.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Ansible Playbook
run-name: ${{ github.actor }} is testing out GitHub Actions 🚀
on: [push]
jobs:
run-ansible-playbook:
runs-on: ubuntu-latest
steps:
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.x"
- name: Install Ansible
run: |
python -m pip install --upgrade pip
pip install ansible
- name: checkout repo
uses: actions/checkout@v4
- name: run ansible-playbook
run: |
cd ${{ github.workspace }}
cat local.yml
ansible-playbook --vault-password-file <(echo ${{ secrets.VAULT_PASS }}) local.yml
15 changes: 10 additions & 5 deletions roles/core/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,11 +98,16 @@
- install
- productivity

- name: Create a symbolic link for fd
- name: Find fdfind executable
ansible.builtin.command: "which fdfind"
register: fdfind_location
changed_when: false
check_mode: false

- name: Create symlink to fdfind
ignore_errors: true
ansible.builtin.file:
src: /usr/bin/fdfind
src: "{{ fdfind_location.stdout }}"
dest: "{{ ansible_env.HOME }}/.local/bin/fd"
state: link
tags:
- install
- productivity
force: true
7 changes: 7 additions & 0 deletions roles/fonts/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,13 @@
- install
- font

- name: Create destination directory if not exist
become: true
ansible.builtin.file:
path: ~/.local/share/fonts/FontAwesome
state: directory
mode: "0755"

- name: Download and extract Font Awesome
become: true
ansible.builtin.unarchive:
Expand Down

0 comments on commit 4e9bc77

Please sign in to comment.