-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(development-environment): add development environment with yarn
Add development environment with yarn to abstract nodemon restarts and husky to format code
- Loading branch information
1 parent
b135736
commit 1e341b6
Showing
9 changed files
with
1,112 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,22 @@ | ||
FROM hayd/alpine-deno:1.0.1 | ||
FROM hayd/alpine-deno:1.0.1 AS base | ||
|
||
USER deno | ||
|
||
WORKDIR /app | ||
WORKDIR /usr/app | ||
|
||
ADD . . | ||
COPY . . | ||
|
||
# development | ||
FROM hayd/alpine-deno:1.0.1 AS development | ||
|
||
RUN apk add --update yarn | ||
|
||
WORKDIR /usr/app | ||
|
||
COPY --from=base /usr/app . | ||
|
||
RUN yarn install | ||
|
||
ENTRYPOINT [ "yarn" ] | ||
|
||
CMD ["dev"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,3 +8,6 @@ kill: | |
|
||
up: | ||
@docker-compose up | ||
|
||
deno: | ||
@yarn deno |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
{ | ||
"name": "deno-playground", | ||
"version": "1.0.0", | ||
"description": "Deno playground", | ||
"main": "index.js", | ||
"scripts": { | ||
"start": "yarn deno", | ||
"deno": "deno run --allow-env --allow-read --allow-net -q src/index.ts", | ||
"dev": "nodemon -e ts --watch src --exec yarn start" | ||
}, | ||
"husky": { | ||
"hooks": { | ||
"pre-commit": "deno fmt src" | ||
} | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/FelipeBarrosCruz/deno-playground.git" | ||
}, | ||
"keywords": [ | ||
"deno", | ||
"playground" | ||
], | ||
"author": "FelipeBarrosCruz <felipe.barros.pt@gmail.com>", | ||
"license": "MIT", | ||
"bugs": { | ||
"url": "https://github.com/FelipeBarrosCruz/deno-playground/issues" | ||
}, | ||
"homepage": "https://github.com/FelipeBarrosCruz/deno-playground#readme", | ||
"devDependencies": { | ||
"husky": "^4.2.5", | ||
"nodemon": "^2.0.4" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.