mspass-team / mspass

Massive Parallel Analysis System for Seismologists
https://mspass.org
BSD 3-Clause "New" or "Revised" License
30 stars 12 forks source link

problem with docker container configuration #201

Closed pavlis closed 3 years ago

pavlis commented 3 years ago

I discovered a minor blemish in what I presume is the configuration for the simple docker container definition for a desktop machine. To avoid the problem noted elsewhere with miniseed net,sta,chan, loc being messed up by save_data I used this construct to create a database handle:

db=Database(dbclient,'usarraytest',db_schema='mspass_lite')

When run on the docker image I get this error:

---------------------------------------------------------------------------
FileNotFoundError                         Traceback (most recent call last)
/usr/local/lib/python3.6/dist-packages/mspasspy/db/schema.py in __init__(self, schema_file)
     26         try:
---> 27             with open(schema_file, 'r') as stream:
     28                     schema_dic = yaml.safe_load(stream)

FileNotFoundError: [Errno 2] No such file or directory: '/mspass/data/yaml/mspass_lite'

Maybe that wouldn't happen if I didn't map /home to a local file system, but the error shows a disconnect in how MSPASS_HOME is set (I think) in the container. I checked running a terminal from the notebook and get what I expected: MSPASS_HOME is set to /mspass. That is clearly not what it should be. I have no clue how to fix that so I need to punt it to you, Ian.

wangyinz commented 3 years ago

This is just a typo, and the error message is telling the truth that there is no such file /mspass/data/yaml/mspass_lite. Instead, you should give the full filename mspass_lite.yaml i.e., Database(dbclient,'usarraytest',db_schema='mspass_lite.yaml').