Skip to content

Commit 5b94585

Browse files
authored
✨ NEW: Initial implementation (#1)
1 parent ca17982 commit 5b94585

File tree

13 files changed

+195
-535
lines changed

13 files changed

+195
-535
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
pull_request:
99

1010
env:
11-
galaxy-name: "marvel-nccr.siesta"
11+
galaxy-name: "marvel-nccr.abinit"
1212

1313
jobs:
1414

@@ -27,6 +27,7 @@ jobs:
2727

2828
strategy:
2929
matrix:
30+
# ubuntu 2004 does not have a defult apt version for libblacs-mpi-dev
3031
distro: [ubuntu1604, ubuntu1804]
3132
fail-fast: false
3233

README.md

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
[![CI](https://github.com/marvel-nccr/ansible-role-siesta/workflows/CI/badge.svg)](https://github.com/marvel-nccr/ansible-role-siesta/actions)
2-
[![Ansible Role](https://img.shields.io/ansible/role/25521.svg)](https://galaxy.ansible.com/marvel-nccr/siesta)
3-
[![Release](https://img.shields.io/github/tag/marvel-nccr/ansible-role-siesta.svg)](https://github.com/marvel-nccr/ansible-role-siesta/releases)
1+
[![CI](https://github.com/marvel-nccr/ansible-role-abinit/workflows/CI/badge.svg)](https://github.com/marvel-nccr/ansible-role-abinit/actions)
2+
[![Ansible Role](https://img.shields.io/ansible/role/25521.svg)](https://galaxy.ansible.com/marvel-nccr/abinit)
3+
[![Release](https://img.shields.io/github/tag/marvel-nccr/ansible-role-abinit.svg)](https://github.com/marvel-nccr/ansible-role-abinit/releases)
44

5-
# Ansible Role: marvel-nccr.siesta
5+
# Ansible Role: marvel-nccr.abinit
66

7-
An Ansible role that installs [Siesta](https://launchpad.net/siesta) on Ubuntu.
7+
An Ansible role that installs [abinit](https://www.abinit.org) on Ubuntu.
88

99
## Installation
1010

11-
`ansible-galaxy install marvel-nccr.siesta`
11+
`ansible-galaxy install marvel-nccr.abinit`
1212

1313
## Role Variables
1414

@@ -19,7 +19,9 @@ See `defaults/main.yml`
1919
```yaml
2020
- hosts: servers
2121
roles:
22-
- role: marvel-nccr.siesta
22+
- role: marvel-nccr.abinit
23+
vars:
24+
abinit_version: "9.2.1"
2325
```
2426
2527
## Development and testing
@@ -28,11 +30,11 @@ This role uses [Molecule](https://molecule.readthedocs.io/en/latest/#) and [Dock
2830
2931
After installing [Docker](https://www.docker.com/):
3032
31-
Clone the repository into a package named `marvel-nccr.siesta` (the folder must be named the same as the Ansible Galaxy name)
33+
Clone the repository into a package named `marvel-nccr.abinit` (the folder must be named the same as the Ansible Galaxy name)
3234

3335
```bash
34-
git clone https://github.com/marvel-nccr/ansible-role-siesta marvel-nccr.siesta
35-
cd marvel-nccr.siesta
36+
git clone https://github.com/marvel-nccr/ansible-role-abinit marvel-nccr.abinit
37+
cd marvel-nccr.abinit
3638
```
3739

3840
Then run:

defaults/main.yml

Lines changed: 52 additions & 122 deletions
Original file line numberDiff line numberDiff line change
@@ -1,125 +1,55 @@
1-
siesta_version: "v4.1-rc2"
2-
siesta_minor_version: "v4.1"
3-
siesta_src: siesta-{{ siesta_version }}
4-
siesta_src_archive: "{{ siesta_src }}.tar.gz"
5-
siesta_code_folder: "/tmp"
6-
siesta_prefix: "/usr/local"
7-
siesta_data_folder: "{{ siesta_prefix }}/share/siesta"
8-
siesta_url: "https://gitlab.com/siesta-project/siesta/-/archive/{{ siesta_version }}/{{ siesta_src_archive }}"
9-
siesta_topdir: "{{ siesta_code_folder }}/siesta-{{ siesta_version }}"
1+
abinit_version: "9.2.1"
2+
abinit_src: abinit-{{ abinit_version }}
3+
abinit_src_archive: "{{ abinit_src }}.tar.gz"
4+
abinit_url: "https://www.abinit.org/sites/default/files/packages/{{ abinit_src_archive }}"
5+
abinit_code_folder: "/tmp"
6+
abinit_built_executable: "{{ abinit_code_folder }}/{{ abinit_src }}/build/src/98_main/abinit"
7+
abinit_prefix: "/usr/local"
108

11-
siesta_enable_netcdf: "1"
12-
siesta_enable_ncdf: "1"
13-
siesta_xmlf90_root: ""
14-
siesta_psml_root: ""
15-
siesta_gridxc_root: ""
16-
siesta_libxc_root: ""
17-
siesta_netcdf_incflags: "-I/usr/include"
18-
siesta_netcdf_libs: "-lnetcdff -lnetcdf"
19-
siesta_blacs_libs: "-lblacsF77init-openmpi -lblacsCinit-openmpi -lblacs-openmpi"
20-
siesta_scalapack_libs: "-lscalapack-openmpi {{ siesta_blacs_libs }}"
21-
siesta_lapack_libs: "-llapack -lblas"
9+
# used for make and runtest -j
10+
abinit_build_cpus: 2
2211

23-
siesta_executables:
24-
- name: siesta
25-
folder: "{{ siesta_prefix }}"
26-
plugin: siesta.siesta
27-
#
28-
# After a recent upgrade, this program is not compatible with the STM plugin :-(
29-
# The version shipped with siesta-4.0.X is still appropriate
30-
# - name: plstm
31-
# folder: "{{ siesta_prefix }}/Util/STM/simple-stm/plstm"
32-
# plugin: siesta.stm
12+
# See https://docs.abinit.org/INSTALL_Ubuntu/
13+
abinit_config_options:
14+
# mandatory libraries
15+
# ("yes" means auto-detect or provide a direct path.)
16+
with_libxc: "yes"
17+
with_hdf5: "yes"
18+
with_netcdf: "yes"
19+
with_netcdf_fortran: "yes"
20+
# MPI settings
21+
with_mpi: "yes"
22+
enable_mpi_io: "yes"
23+
# linear algebra settings
24+
with_linalg_flavor: "netlib"
25+
LINALG_LIBS: "-L/usr/lib/x86_64-linux-gnu -llapack -lblas"
3326

34-
# Utilities in Util/
35-
siesta_utils:
36-
- name: denchar
37-
dir: Util/Denchar/Src
38-
description: >-
39-
Charge density and wave-function plotting
40-
- name: g2c_ng
41-
dir: Util/Grid
42-
description: >-
43-
Converter from native grid to Cube format
44-
- name: macroave
45-
dir: Util/Macroave/Src
46-
description: >-
47-
Macroscopic averages processor
48-
- name: mprop
49-
dir: Util/COOP
50-
description: >-
51-
COOP/COHP processor
52-
- name: fat
53-
dir: Util/COOP
54-
description: >-
55-
Fat-bands processor
56-
- name: gnubands
57-
dir: Util/Bands
58-
description: >-
59-
Band-structure plotting
60-
- name: eigfat2plot
61-
dir: Util/Bands
62-
description: >-
63-
Fat-bands plotting
64-
- name: tbtrans
65-
dir: Util/TS/TBtrans
66-
description: >-
67-
Transport post-processor
68-
69-
siesta_pps:
70-
# - name: nc-sr-pbe-stringent-0.4
71-
# folder: nc-sr-pbe-stringent-0.4
72-
# file: nc-sr-04_pbe_stringent_psml.tgz
73-
# url: http://departments.icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo/
74-
# home_page: http://www.pseudo-dojo.org/
75-
# description: >-
76-
# Norm-conserving scalar-relativistic pseudopotentials v0.4 for the PBE
77-
# functional (NC SR ONCVPSP v0.4) from pseudo-dojo.org.
78-
# Accuracy "stringent", format PSML.
79-
# - name: nc-sr-pbe-standard-0.4
80-
# folder: nc-sr-pbe-standard-0.4
81-
# file: nc-sr-04_pbe_standard_psml.tgz
82-
# url: http://departments.icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo/
83-
# home_page: http://www.pseudo-dojo.org/
84-
# description: >-
85-
# Norm-conserving scalar-relativistic pseudopotentials v0.4 for the PBE
86-
# functional (NC SR ONCVPSP v0.4) from pseudo-dojo.org.
87-
# Accuracy "standard", format PSML.
88-
- name: nc-sr-pbe-standard-0.4
89-
file: nc-sr-04_pbe_standard-psf.tgz
90-
url: https://icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo
91-
home_page: http://www.pseudo-dojo.org/
92-
description: >-
93-
Norm-conserving scalar-relativistic pseudopotentials v0.4 for the PBE
94-
functional (NC SR ONCVPSP v0.4) from pseudo-dojo.org.
95-
Accuracy "standard", format PSF.
96-
# - name: nc-fr-pbe-stringent-0.4
97-
# folder: nc-fr-pbe-stringent-0.4
98-
# file: nc-fr-04_pbe_stringent_psml.tgz
99-
# url: http://departments.icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo/
100-
# home_page: http://www.pseudo-dojo.org/
101-
# description: >-
102-
# Norm-conserving fully-relativistic pseudopotentials v0.4 for the PBE
103-
# functional (NC FR ONCVPSP v0.4) from pseudo-dojo.org.
104-
# Accuracy "stringent", format PSML.
105-
# - name: nc-fr-pbe-standard-0.4
106-
# folder: nc-fr-pbe-standard-0.4
107-
# file: nc-fr-04_pbe_standard_psml.tgz
108-
# url: http://departments.icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo/
109-
# home_page: http://www.pseudo-dojo.org/
110-
# description: >-
111-
# Norm-conserving fully-relativistic pseudopotentials v0.4 for the PBE
112-
# functional (NC FR ONCVPSP v0.4) FRom pseudo-dojo.org.
113-
# Accuracy "standard", format PSML.
114-
- name: nc-fr-pbe-standard-0.4
115-
file: nc-fr-04_pbe_standard-psf.tgz
116-
url: https://icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo
117-
home_page: http://www.pseudo-dojo.org/
118-
description: >-
119-
Norm-conserving fully-relativistic pseudopotentials v0.4 for the PBE
120-
functional (NC FR ONCVPSP v0.4) FRom pseudo-dojo.org.
121-
Accuracy "standard", format PSF.
122-
123-
siesta_tests:
124-
- h2o
125-
- mno_ldau
27+
abinit_tests:
28+
# - atompaw
29+
# - bigdft
30+
# - bigdft_paral
31+
# - built-in
32+
- etsf_io
33+
- fast
34+
# - gpu
35+
- libxc[:4]
36+
- mpiio
37+
- paral
38+
# - psml
39+
# - seq
40+
# - tutoparal
41+
# - tutorespfn
42+
# - tutorial
43+
# - unitary
44+
# - v1
45+
# - v2
46+
# - v3
47+
# - v4
48+
# - v5
49+
# - v6
50+
# - v67mbpt
51+
# - v7
52+
# - v8
53+
# - v9
54+
# - vdwxc
55+
# - wannier90

meta/main.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
allow_duplicates: false
22

33
galaxy_info:
4-
author: "MARVEL NCCR / Siesta project"
5-
description: "An Ansible role that installs [Siesta](https://gitlab.com/siesta-project/siesta) on Ubuntu."
4+
author: "MARVEL NCCR"
5+
description: "An Ansible role that installs [abinit](https://www.abinit.org) on Ubuntu."
66
license: MIT
77
min_ansible_version: 2.7
88
platforms:
@@ -14,3 +14,8 @@ galaxy_info:
1414
- ubuntu
1515
- application
1616
- science
17+
18+
dependencies:
19+
- name: marvel-nccr.python
20+
version: v0.2.0
21+
tags: [never]

molecule/default/converge.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@
55
- name: Update apt cache.
66
apt:
77
update_cache: yes
8-
cache_valid_time: 600
9-
when: ansible_os_family == 'Debian'
8+
cache_valid_time: 6000
9+
when: ansible_os_family|lower == 'debian'
1010

1111
vars:
12-
run_tests: false
12+
run_tests: true
13+
ansible_python_interpreter: /usr/bin/python3
1314

1415
roles:
15-
- role: marvel-nccr.siesta
16+
- role: marvel-nccr.abinit

molecule/default/molecule.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
dependency:
22
name: galaxy
3-
# requirements_file: molecule/default/requirements.yml
3+
requirements_file: molecule/default/requirements.yml
44
driver:
55
name: docker
66
platforms:
@@ -16,7 +16,13 @@ platforms:
1616
LANG: "en_US.UTF-8"
1717
provisioner:
1818
name: ansible
19+
# log: true # for debugging
1920
playbooks:
2021
converge: converge.yml
21-
# Remove Ansible no_log settings for debugging
22-
# log: true
22+
config_options:
23+
defaults:
24+
# nicer stdout printing
25+
stdout_callback: yaml
26+
bin_ansible_callbacks: true
27+
# add timing to tasks
28+
callback_whitelist: profile_tasks

molecule/default/requirements.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
- role: marvel-nccr.python
2+
version: v0.2.0

0 commit comments

Comments
 (0)