Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make config_example.yaml work #52

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,19 @@ And a apache config:
## Docker

There is a dockerfile provided that can be used for easy running.
It needs a working configuratiin and a data directory.
It needs a working configuration and a data directory.
The data directory is mounted to /data within the container. So make
sure that your database is within that path.

$ docker run -v <my-cfg>:/config.yaml -v <data-dir>:/data <image-name>
$ git clone https://github.com/janLo/meet-and-eat-registration-system.git
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would seperate this, as it has nothing to do with the actual docker deployment

$ cd meet-and-eat-registration-system
$ docker build . -t <image-name>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Give here the alternatives:

  • Build the image yourself.
  • Pull the image from the docker hub.

$ docker run -v <my-cfg>:/config.yaml -v <data-dir>:/data -p 8080:8080 <image-name>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change -p 8080:8080 to [<hostaddress>]:<hostport>:8080, as the first one is the special case where you publish the port on 8080 on any address of your host system. This is not what you want in production.


Now try to access the Websites:

localhost:8080/
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you really want to give this, then exchange localhost:8080 and 127.0.0.1:8080 with <hostaddress>:<hostport>:8080 and either give a full list of all accessible endpoints or remove /admin/login, as /admin redirects to that.

127.0.0.1:8080/
... /public
... /admin
... /admin/login
9 changes: 5 additions & 4 deletions config_example.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
SECRET_KEY: "gocu5eYoosh8oocoozeeG9queeghae7ushahp9ufaighoo5gex1vulaexohtepha"

# this is the dbapi connection string for sqlalchemy
DB_CONNECTION: "file:////data/mue.db"
DB_CONNECTION: "sqlite:////data/mue.db"

# Turn this off in production!
DEBUG: true

# This is useful for deployment behind a reverse proxy
SERVER_NAME: 'localhost:5000'
APPLICATION_ROOT: "/"
BEHIND_REVERSE_PROXY: false
#SERVER_NAME: 'localhost:5000'
#APPLICATION_ROOT: "/"

# Register a mapquest app key at http://developer.mapquest.com/web/products/open
MAPQUEST_KEY: ""
Expand Down Expand Up @@ -50,7 +50,8 @@ ADMIN_PASSWORD: "test"
# Format: "yyyy-mm-dd HH:MM"
REGISTER_END: "2020-05-01 22:30"
MAX_TEAMS: 51
VOLUME: 11
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if we have to change this in the example but ok.

# this event happens the VOLUMEth time
VOLUME: 13

CENTER_POINT: [51.05299472808838, 13.742453455924988]

Expand Down