Skip to content

Commit 6bb32c2

Browse files
committed
fix: Unable to run migrations in latest image. Added option to run non-SSL migration in production
1 parent 1d5f735 commit 6bb32c2

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed

Dockerfile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ COPY . .
1414

1515
RUN yarn build && \
1616
yarn --production --ignore-scripts --prefer-offline && \
17-
rm -rf server && \
1817
rm -rf shared && \
1918
rm -rf app
2019

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,8 @@ For a manual self-hosted production installation these are the suggested steps:
4444
1. `REDIS_URL` (run your own local copy of Redis, or use a cloud service)
4545
1. `URL` (the public facing URL of your installation)
4646
1. `AWS_` (all of the keys beginning with AWS)
47-
1. Migrate database schema with `yarn sequelize:migrate`
47+
1. Migrate database schema with `yarn sequelize:migrate`. Production assumes an SSL connection, if
48+
Postgres is on the same machine and is not SSL you can migrate with `yarn sequelize:migrate --env=production-ssl-disabled`.
4849
1. Start the service with any daemon tools you prefer. Take PM2 for example, `NODE_ENV=production pm2 start ./build/server/index.js --name outline `
4950
1. Visit http://you_server_ip:3000 and you should be able to see Outline page
5051

server/config/database.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,9 @@
1515
"rejectUnauthorized": false
1616
}
1717
}
18+
},
19+
"production-ssl-disabled": {
20+
"use_env_variable": "DATABASE_URL",
21+
"dialect": "postgres"
1822
}
1923
}

0 commit comments

Comments
 (0)