<commit_before>

API server
----------


Build image:
```bash
export TAG=`date +"%Y%m%d.%H%M"`
docker build --force-rm --no-cache --rm -t  mgrast/api:${TAG}  https://raw.githubusercontent.com/MG-RAST/MG-RAST/api/docker/Dockerfile
```

Get config: (private mcs git repo)
```bash
if cd /home/core/mgrast-config; then git pull; else cd /home/core/ ; git clone <EMAIL>:mgrast-config.git ; fi
```


Start container:
```bash
docker run -t -i --name api -v /home/core/mgrast-config/services/api-server:/api-server-conf -v /media/ephemeral/api-server-data:/m5nr -p 80:80 mgrast/api:${TAG} /usr/local/apache2/bin/httpd -DFOREGROUND -f /MG-RAST/conf/httpd.conf
```<commit_msg>download data instructions<commit_after>

API server
----------


Build image:
```bash
export TAG=`date +"%Y%m%d.%H%M"`
docker build --force-rm --no-cache --rm -t  mgrast/api:${TAG}  https://raw.githubusercontent.com/MG-RAST/MG-RAST/api/docker/Dockerfile
```

Get config: (private mcs git repo)
```bash
if cd /home/core/mgrast-config; then git pull; else cd /home/core/ ; git clone <EMAIL>:mgrast-config.git ; fi
```

Download data
```bash
docker run -t -i --name api -v /media/ephemeral/api-server-data:/m5nr mgrast/api:${TAG} /MG-RAST/bin/download_m5nr_blast.sh
docker rm api
```

Start container:
```bash
docker run -t -i --name api -v /home/core/mgrast-config/services/api-server:/api-server-conf -v /media/ephemeral/api-server-data:/m5nr -p 80:80 mgrast/api:${TAG} /usr/local/apache2/bin/httpd -DFOREGROUND -f /MG-RAST/conf/httpd.conf
```
{'fraction_non_alphanumeric': 0.19483101391650098, 'fraction_numerical': 0.00927766732935719, 'mean_word_length': 3.5619335347432024, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 3, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7340417', 'n_tokens_mistral': 637, 'n_tokens_neox': 587, 'n_words': 132}