Skip to content

Commit

Permalink
Merge pull request #121 from CCBR/fix-reconfig
Browse files Browse the repository at this point in the history
fix: reconfig needs to use platform-specific configfile
  • Loading branch information
kelly-sovacool authored Oct 17, 2024
2 parents c601d81 + f7a0837 commit d8f9cf0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@

- CHARLIE was falsely throwing a file permissions error for tempdir values containing bash variables. (#118, @kelly-sovacool)
- Singularity bind paths were not being set properly. (#119, @kelly-sovacool)
- Update docker containers to set `$PYTHONPATH`. (#119, @kelly-sovacool)
- Otherwise, this environment variable can be carried over and cause package conflicts when singularity is not run with `-C`.
- Fix `reconfig` to correctly replace variables in the config file. (#121, @kelly-sovacool)

## CHARLIE 0.11.0

Expand Down
10 changes: 7 additions & 3 deletions charlie
Original file line number Diff line number Diff line change
Expand Up @@ -294,9 +294,13 @@ function reconfig(){
# rebuild config file and replace the config.yaml in the WORKDIR
# this is only for dev purposes when new key-value pairs are being added to the config file
check_essential_files
sed -e "s/PIPELINE_HOME/${PIPELINE_HOME//\//\\/}/g" -e "s/WORKDIR/${WORKDIR//\//\\/}/g" \
${PIPELINE_HOME}/config/config.yaml |\
cat - ${PIPELINE_HOME}/config/containers.yaml > $WORKDIR/config.yaml
sed -e "s/PIPELINE_HOME/${PIPELINE_HOME//\//\\/}/g" \
-e "s/WORKDIR/${WORKDIR//\//\\/}/g" \
-e "s/HOST/${HOST}/g" \
-e "s/ADDITIVES/${ADDITIVES}/g" \
-e "s/VIRUSES/${VIRUSES}/g" \
${PIPELINE_HOME}/config/$PLATFORM/config.yaml |\
cat - ${PIPELINE_HOME}/config/containers.yaml > $CONFIGFILE
echo "$WORKDIR/config.yaml has been updated!"
}

Expand Down

0 comments on commit d8f9cf0

Please sign in to comment.