-
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.
- Loading branch information
0 parents
commit 7716425
Showing
2 changed files
with
118 additions
and
0 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,91 @@ | ||
:author: Ted Won | ||
:email: iamtedwon@gmail.com | ||
:toc: left | ||
:toclevels: 5 | ||
:sectnums: | ||
:sectnumlevels: 5 | ||
:icons: font | ||
:idprefix: | ||
:idseparator: - | ||
|
||
|
||
= https://github.com/tedwon/quokka[Quokka Project] | ||
|
||
== https://github.com/tedwon/quokka-backend[Simple Memo App Project based on Quarkus with Java] | ||
|
||
== Quokka Projects | ||
|
||
https://github.com/tedwon/quokka | ||
|
||
=== Quokka Backend Project | ||
|
||
https://github.com/tedwon/quokka-backend | ||
|
||
https://hub.docker.com/repository/docker/tedwon/quokka-backend | ||
|
||
|
||
=== Quokka Frontend Project | ||
|
||
https://github.com/tedwon/quokka-frontend | ||
|
||
https://hub.docker.com/repository/docker/tedwon/quokka-frontend | ||
|
||
=== Quokka DB Project | ||
|
||
https://hub.docker.com/_/postgres | ||
|
||
|
||
== Run Quokka Projects with Docker | ||
|
||
[source,bash,options="nowrap"] | ||
---- | ||
docker network create quokka_net | ||
sudo mkdir /private/var/quokka_db_data | ||
sudo chown -R <user>:<group> /private/var/quokka_db_data | ||
ls -al /var/quokka_db_data | ||
docker run --rm=true -itd \ | ||
--name quokka-db \ | ||
-v /var/quokka_db_data:/var/lib/postgresql/data \ | ||
-e POSTGRES_USER=quokka \ | ||
-e POSTGRES_PASSWORD=quokka \ | ||
-e POSTGRES_DB=quokka_db \ | ||
-p 5432:5432 \ | ||
--network quokka_net \ | ||
postgres:latest | ||
cd quokka-backend | ||
./mvnw clean package | ||
docker build -f src/main/docker/Dockerfile.jvm -t tedwon/quokka-backend:0.1.0 . | ||
docker run -i --rm -p 8080:8080 --network quokka_net tedwon/quokka-backend:0.1.0 | ||
cd quokka-frontend | ||
docker build -t tedwon/quokka-frontend:0.1.0 . | ||
docker run -p 3000:3000 --network quokka_net tedwon/quokka-frontend:0.1.0 | ||
---- | ||
|
||
== Run Quokka with Docker Compose | ||
|
||
[source,bash,options="nowrap"] | ||
---- | ||
docker-compose -f docker-compose.yml up -d | ||
---- | ||
|
||
== Stop Quokka with Docker Compose | ||
|
||
[source,bash,options="nowrap"] | ||
---- | ||
docker-compose -f docker-compose.yml down | ||
---- | ||
|
||
== Push Quokka projects to Docker Hub | ||
|
||
* https://hub.docker.com/repository/docker/tedwon/quokka-backend | ||
* https://hub.docker.com/repository/docker/tedwon/quokka-backend | ||
|
||
[source,bash,options="nowrap"] | ||
---- | ||
docker push tedwon/quokka-backend:0.1.0 | ||
docker push tedwon/quokka-frontend:0.1.0 | ||
---- |
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,27 @@ | ||
version: "3.9" | ||
services: | ||
db: | ||
image: postgres:latest | ||
volumes: | ||
- /var/quokka_db_data:/var/lib/postgresql/data | ||
ports: | ||
- "5432:5432" | ||
restart: always | ||
environment: | ||
POSTGRES_USER: quokka | ||
POSTGRES_PASSWORD: quokka | ||
POSTGRES_DB: quokka_db | ||
backend: | ||
depends_on: | ||
- db | ||
image: tedwon/quokka-backend:0.1.0 | ||
ports: | ||
- "8080:8080" | ||
restart: always | ||
frontend: | ||
depends_on: | ||
- backend | ||
image: tedwon/quokka-frontend:0.1.0 | ||
ports: | ||
- "3000:3000" | ||
restart: always |