Skip to content

Commit

Permalink
Merge branch 'release/v1.3.3'
Browse files Browse the repository at this point in the history
  • Loading branch information
namnhce committed Jun 19, 2024
2 parents 9cfd71b + e246c31 commit 8a5096b
Show file tree
Hide file tree
Showing 9 changed files with 615 additions and 21 deletions.
13 changes: 12 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,18 @@ TOOLS_IMAGE=dwarvesv/fortress-tools:latest
APP_ENVIRONMENT=docker run --rm -v ${PWD}:/${APP_NAME} -w /${APP_NAME} --net=host ${TOOLS_IMAGE}
SWAGGER_VERSION = v1.16.1

.PHONY: setup init build dev test migrate-up migrate-down ci
.PHONY: setup shel colima-start colima-stop init build dev test migrate-up migrate-down ci

shell:
@if ! command -v devbox >/dev/null 2>&1; then curl -fsSL https://get.jetpack.io/devbox | bash; fi
@devbox install
@devbox shell

colima-start:
colima start --cpu 1 --memory 2 --disk 30

colima-stop:
@colima stop

setup:
docker pull ${TOOLS_IMAGE}
Expand Down
27 changes: 24 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,31 @@ This repository is the official BE service for Fortress

## How to contribute

### Prerequisites
### Setup local development environment (pick one of following ways)

1. Go installed
2. Docker installed
#### Using DEVBOX

1. Create isolated shell using devbox

```
make shell
```

2. Start Colima as container runtime

```
make colima-start
```

Related issue when initiating development environment first time using colima
- [docker-credential-desktop not installed or not available in PATH](https://stackoverflow.com/questions/67642620/docker-credential-desktop-not-installed-or-not-available-in-path/72888813#72888813)
- tltr: Cheating by removing `credsStore` in the `~/.docker/config.json`. Or installing `osxkeychain`

#### Using your machine environment

1. Install Golang

2. Install Docker

### How to run source code locally

Expand Down
25 changes: 25 additions & 0 deletions devbox.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"$schema": "https://raw.githubusercontent.com/jetify-com/devbox/0.10.7/.schema/devbox.schema.json",
"packages": [
"docker@latest",
"docker-compose@latest",
"git@latest",
"qemu@latest",
"vim@latest",
"colima@latest",
"air@latest",
"[email protected]",
"[email protected]"
],
"shell": {
"scripts": {
"test": [
"echo \"Error: no test specified\" && exit 1"
]
}
},
"env": {
"PATH": "/usr/bin:$PWD/.devbox/nix/profile/default/bin:$PATH",
"GOPATH": "$PWD/.devbox/nix/profile/default/share/go"
}
}
Loading

0 comments on commit 8a5096b

Please sign in to comment.