Skip to content

Commit

Permalink
wip: fixing the build
Browse files Browse the repository at this point in the history
  • Loading branch information
mkllnk committed Jun 13, 2024
1 parent 1e669a3 commit 9c51e70
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 1 deletion.
1 change: 1 addition & 0 deletions inventory/group_vars/all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ postgres_encoding: en_US.utf8
# to the defaults if present. Make sure you use the "list" notation with the dashes!

postgresql_version: "{% if ansible_distribution_major_version == '16' %}9.5{% elif ansible_distribution_major_version == '18' %}10{% else %}12{% endif %}"
postgresql_version: "{% if ansible_distribution_major_version == '16' %}9.5{% elif ansible_distribution_major_version == '18' %}10{% elif ansible_distribution_major_version == '20' %}12{% else %}14{% endif %}"
postgresql_data_dir: "/var/lib/postgresql/{{ postgresql_version }}/main"
postgresql_bin_path: "/usr/lib/postgresql/{{ postgresql_version }}/bin"
postgresql_config_path: "/etc/postgresql/{{ postgresql_version }}/main"
Expand Down
26 changes: 26 additions & 0 deletions lxc-setup
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
apt install lxd
lxd init # enter a lot for default settings
usermod -aG lxd maikel

su - "$USER" # starts a new shell with the new group added

lxc launch ubuntu:22.04 ofn-dev
lxc exec ofn-dev -- sh -c 'cat >> .ssh/authorized_keys' < ~/.ssh/id_rsa.pub

lxc list # to get IP address
echo '
Host ofn.local
Hostname 10.52.128.246
User root
UserKnownHostsFile /dev/null
StrictHostKeyChecking no
PasswordAuthentication no
LogLevel FATAL
' >> "$HOME/.ssh/config"

ansible-playbook -l lxc site.yml

# Fail

lxc restart ofn-dev
ansible-playbook -l lxc playbooks/provision.yml
2 changes: 1 addition & 1 deletion roles/common/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
vars:
packages:
# Ansible support
- python-pycurl
- python3-pycurl
- python3-psycopg2

# unknown why or if needed
Expand Down

0 comments on commit 9c51e70

Please sign in to comment.