-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(docs): running on docker (#161)
* refactor(env): removing unsed variable * docs(docker): running on docker docs
- Loading branch information
1 parent
e5cab90
commit b9fbf9a
Showing
4 changed files
with
36 additions
and
2 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
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,5 @@ | ||
# Cuenta Única Ciudadana | ||
|
||
## Documentation | ||
|
||
- [Run on docker](./docker/how-to-run-on-docker.md) |
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,31 @@ | ||
# How to run on Docker | ||
|
||
If you're trying to run this project on a local machine with Docker, follow this steps. | ||
|
||
## Load all the environment variables from the .env file | ||
|
||
```sh | ||
export $(grep -v '^#' .env | xargs) | ||
``` | ||
|
||
## Build the image | ||
|
||
```sh | ||
docker build \ | ||
--secret id=AWS_EXPORTS_JSON,src=$AWS_EXPORTS_PATH \ | ||
--build-arg SENTRY_ORG=$SENTRY_ORG \ | ||
--build-arg SENTRY_PROJECT=$SENTRY_PROJECT \ | ||
--build-arg SENTRY_AUTH_TOKEN=$SENTRY_AUTH_TOKEN \ | ||
--build-arg NEXT_PUBLIC_SENTRY_DSN=$NEXT_PUBLIC_SENTRY_DSN \ | ||
--build-arg NEXT_PUBLIC_RECAPTCHA_SITE_KEY=$NEXT_PUBLIC_RECAPTCHA_SITE_KEY \ | ||
-t $IMAGE_NAME . | ||
``` | ||
|
||
## Run the image | ||
|
||
```sh | ||
docker run \ | ||
--env-file=./.env \ | ||
-p 3000:3000 \ | ||
$IMAGE_NAME | ||
``` |
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