Skip to content

activate bloom

activate bloom #119

Workflow file for this run

name: BLOOM CENTOS
on:
push:
branches:
- 'main'
tags:
- '*'
pull_request:
branches:
- '**'
jobs:
centos-stream-job:
runs-on: ubuntu-latest # Host OS for the Docker container
container:
image: quay.io/centos/centos:stream9 # Using CentOS Stream 9
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Set up Python
run: |
dnf install -y python3
python3 -m ensurepip
python3 -m pip install --upgrade pip
- name: Set up Miniconda
run: |
dnf install -y wget sudo
useradd -m bloom
ls -lta .
cat bloom_lims/env/install_postgres.sh
chmod -R a+wrx ./*
chown -R bloom:bloom ./*
cp -r ./* /home/bloom/
chown -R bloom:bloom /home/bloom/*
ogpwd=$PWD
echo $PWD
echo GOGOGOGO
echo 'bloom ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
# Create the setup script
cat <<'EOF' >setup_bloom.sh
#!/bin/bash
cd /home/bloom
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh
bash miniconda.sh -b -p /home/bloom/miniconda
export PATH="/home/bloom/miniconda/bin:$PATH"
conda init
pwd
export USER=bloom
source /home/bloom/.bashrc
conda env list
cd $ogpwd
ls -lta .
sleep 5
echo $PWD
ls -lta ./
sleep 10
source bloom_lims/env/install_postgres.sh
pytest
EOF
# Make the script executable
chmod +x setup_bloom.sh
# Execute the script as the 'bloom' user
sudo -u bloom ./setup_bloom.sh