Merge pull request #2860 from omnivore-app/fix/self-hosting-login
fix demo user not able to login when self hosting
This commit is contained in:
@ -56,29 +56,6 @@ services:
|
||||
ports:
|
||||
- "9200:9200"
|
||||
|
||||
kibana:
|
||||
image: docker.elastic.co/kibana/kibana:7.17.1
|
||||
container_name: "omnivore-kibana"
|
||||
environment:
|
||||
- ELASTICSEARCH_HOSTS=http://elastic:9200
|
||||
depends_on:
|
||||
- elastic
|
||||
ports:
|
||||
- "5601:5601"
|
||||
profiles:
|
||||
- debug
|
||||
|
||||
redis:
|
||||
image: "redis:6.2.7"
|
||||
container_name: "omnivore-redis"
|
||||
healthcheck:
|
||||
test: "exit 0"
|
||||
interval: 2s
|
||||
timeout: 12s
|
||||
retries: 3
|
||||
ports:
|
||||
- "6379:6379"
|
||||
|
||||
api:
|
||||
build:
|
||||
context: .
|
||||
@ -100,21 +77,17 @@ services:
|
||||
- PG_POOL_MAX=20
|
||||
- ELASTIC_URL=http://elastic:9200
|
||||
- JAEGER_HOST=jaeger
|
||||
- IMAGE_PROXY_URL=http://localhost:9999
|
||||
- IMAGE_PROXY_SECRET=some-secret
|
||||
- JWT_SECRET=some_secret
|
||||
- SSO_JWT_SECRET=some_sso_secret
|
||||
- CLIENT_URL=http://localhost:3000
|
||||
- GATEWAY_URL=http://localhost:8080/api
|
||||
- CONTENT_FETCH_URL=http://content-fetch:8080/?token=some_token
|
||||
- REMINDER_TASK_HANDLER_URL=/svc/reminders/trigger
|
||||
depends_on:
|
||||
migrate:
|
||||
condition: service_completed_successfully
|
||||
elastic:
|
||||
condition: service_healthy
|
||||
redis:
|
||||
condition: service_healthy
|
||||
|
||||
web:
|
||||
build:
|
||||
@ -151,16 +124,3 @@ services:
|
||||
depends_on:
|
||||
api:
|
||||
condition: service_healthy
|
||||
|
||||
rule-handler:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: ./packages/rule-handler/Dockerfile
|
||||
container_name: "omnivore-rule-handler"
|
||||
ports:
|
||||
- "9091:8080"
|
||||
environment:
|
||||
- PUBSUB_VERIFICATION_TOKEN=some_token
|
||||
depends_on:
|
||||
migrate:
|
||||
condition: service_completed_successfully
|
||||
|
||||
@ -165,6 +165,7 @@ const nullableEnvVars = [
|
||||
'THUMBNAIL_TASK_HANDLER_URL',
|
||||
'RSS_FEED_TASK_HANDLER_URL',
|
||||
'SENDGRID_VERIFICATION_TEMPLATE_ID',
|
||||
'REMINDER_TASK_HANDLER_URL',
|
||||
] // Allow some vars to be null/empty
|
||||
|
||||
/* If not in GAE and Prod/QA/Demo env (f.e. on localhost/dev env), allow following env vars to be null */
|
||||
|
||||
@ -6,8 +6,8 @@ yarn workspace @omnivore/db migrate
|
||||
psql --host $PG_HOST -U $PG_USER -d $PG_DB -c "GRANT omnivore_user TO app_user;" || true
|
||||
echo "granted omnivore_user to app_user"
|
||||
|
||||
# create demo user with email: demo@omnivore.app, password: demo
|
||||
# create demo user with email: demo@omnivore.app, password: demo_password
|
||||
USER_ID=$(uuidgen)
|
||||
PASSWORD='$2a$10$nxdWohvkWWpmQ28aTq0BK./pRgt6/WDrWyArvod8uWqxpFu/cfVoy'
|
||||
psql --host $PG_HOST -U $PG_USER -d $PG_DB -c "INSERT INTO omnivore.user (id, source, email, source_user_id, name, password) VALUES ('$USER_ID', 'EMAIL', 'demo@omnivore.app', 'demo@omnivore.app', 'Demo User', '$PASSWORD'); INSERT INTO omnivore.user_profile (user_id, username) VALUES ('$USER_ID', 'demo');"
|
||||
echo "created demo user with email: demo@omnivore.app, password: demo"
|
||||
PASSWORD='$2a$10$41G6b1BDUdxNjH1QFPJYDOM29EE0C9nTdjD1FoseuQ8vZU1NWtrh6'
|
||||
psql --host $PG_HOST -U $PG_USER -d $PG_DB -c "INSERT INTO omnivore.user (id, source, email, source_user_id, name, password) VALUES ('$USER_ID', 'EMAIL', 'demo@omnivore.app', 'demo@omnivore.app', 'Demo User', '$PASSWORD'); INSERT INTO omnivore.user_profile (user_id, username) VALUES ('$USER_ID', 'demo_user');"
|
||||
echo "created demo user with email: demo@omnivore.app, password: demo_password"
|
||||
|
||||
Reference in New Issue
Block a user