Skip to content

Commit

Permalink
fix: take .env in consideration when using Docker
Browse files Browse the repository at this point in the history
  • Loading branch information
louistiti committed Jun 6, 2019
1 parent 88b8110 commit d38e609
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 0 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
node_modules/
bridges/python/.venv/*

.env
!bridges/python/.venv/.gitkeep
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM node:10-alpine
ENV IS_DOCKER true
WORKDIR /app

# Install system packages
Expand Down
2 changes: 2 additions & 0 deletions scripts/setup/setup-dotenv.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ export default () => new Promise(async (resolve) => {
if (!fs.existsSync('.env')) {
createDotenv()

resolve()
} else if (process.env.IS_DOCKER === 'true') {
resolve()
} else {
const answer = await prompt({
Expand Down

0 comments on commit d38e609

Please sign in to comment.