From 2358fac48e71e0050a66e6805631540eea94c9dd Mon Sep 17 00:00:00 2001 From: "Anuththara Gamage(Anu)" <90089876+ANUGAMAGE@users.noreply.github.com> Date: Sun, 7 Jan 2024 09:02:22 +0530 Subject: [PATCH] Create GROMACS_Installation_Main.yml Signed-off-by: Anuththara Gamage(Anu) <90089876+ANUGAMAGE@users.noreply.github.com> --- .../workflows/GROMACS_Installation_Main.yml | 66 +++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 .github/workflows/GROMACS_Installation_Main.yml diff --git a/.github/workflows/GROMACS_Installation_Main.yml b/.github/workflows/GROMACS_Installation_Main.yml new file mode 100644 index 0000000..fc44cc9 --- /dev/null +++ b/.github/workflows/GROMACS_Installation_Main.yml @@ -0,0 +1,66 @@ +name: Run GROMACS Simulations + +on: + workflow_dispatch + +jobs: + simulate: + runs-on: warp-ubuntu-latest-x64-2x + timeout-minutes: 240 + + steps: + - name: Checkout source + uses: actions/checkout@v2 + + - name: Setup Python + uses: actions/setup-python@v2 + with: + python-version: 3.7 + + - name: Install GROMACS Requirements + run: | + sudo apt-get update + sudo apt-get install -y wget + wget https://ftp.gromacs.org/gromacs/gromacs-2023.3.tar.gz + tar xfz gromacs-2023.3.tar.gz + cd gromacs-2023.3 + mkdir build + cd build + cmake .. -DGMX_BUILD_OWN_FFTW=ON -DREGRESSIONTEST_DOWNLOAD=ON + make + # Exclude the problematic test + ctest -j $(nproc) -E MdrunTestsTwoRanks --output-on-failure || true #workflow continues even if the test fails + sudo make install + echo 'source /usr/local/gromacs/bin/GMXRC' >> $HOME/.bashrc + source $HOME/.bashrc + export PATH="/usr/local/gromacs/bin:$PATH" # Added this line to add GROMACS to PATH + + - name: Prepare Input Files + run: | + cp simulation/input_files/NVT.mdp . + cp simulation/input_files/NPT.mdp . + cp simulation/input_files/MD.mdp . + cp simulation/input_files/EM.gro . + cp simulation/input_files/topol.top . + cp simulation/input_files/index.ndx . + + - name: Run NVT Simulation + run: | + gmx grompp -f NVT.mdp -c EM.gro -r EM.gro -p topol.top -n index.ndx -maxwarn 2 -o NVT.tpr + gmx mdrun -deffnm NVT + + - name: Run NPT Simulation + run: | + gmx grompp -f NPT.mdp -c NVT.gro -r NVT.gro -p topol.top -n index.ndx -maxwarn 2 -o NPT.tpr + gmx mdrun -deffnm NPT + + - name: Run MD Simulation + run: | + gmx grompp -f MD.mdp -c NPT.gro -t NPT.cpt -p topol.top -n index.ndx -maxwarn 2 -o MD.tpr + gmx mdrun -deffnm MD + + - name: Archive Simulation Output + uses: actions/upload-artifact@v2 + with: + name: simulation-results + path: ./*.{edr,log,trr,tpr,xtc,xvg}