๐Ÿ‘ฉโ€๐Ÿš’ Firefighters API written in Gleam!
lustre gleam

:art: organize recipes

kacaii.dev 300697c7 4e0d8c81

verified
+9 -15
+9 -15
justfile
··· 41 41 test: 42 42 just server::test 43 43 44 - # Clean pod resources 45 - [group("podman")] 46 - clean: 47 - podman pod rm -f {{ pod_name }} 48 - 44 + # Start all containers 49 45 [group("podman")] 50 - up: 51 - just create-pod 52 - just init-database 53 - just build-backend 54 - just init-backend 46 + up: _create-pod init-database init-backend 55 47 @echo {{ GREEN }}"Listening on http://0.0.0.0:8000"{{ NORMAL }} 56 48 49 + # Stops the application and free resources 57 50 [group("podman")] 58 51 down: 52 + podman pod exists {{ pod_name }} || false 59 53 podman pod stop {{ pod_name }} 60 54 podman pod rm {{ pod_name }} 61 55 62 56 # Init the database container 63 57 [group("podman")] 64 - @init-database: 58 + @init-database: _create-pod 65 59 podman run -d --pod {{ pod_name }} --name postgres-database {{ pg_env }} \ 66 60 {{ pg_health_cmd }} {{ pg_health_conf }} {{ pg_health_start_period }} \ 67 61 {{ pg_volume }} {{ pg_image }} 68 62 69 63 # Init the application container 70 64 [group("podman")] 71 - @init-backend: 65 + @init-backend: _create-pod _build-backend 72 66 podman run -d \ 73 67 --pod {{ pod_name }} \ 74 68 --name backend \ ··· 77 71 78 72 # Build application container 79 73 [group("podman")] 80 - @build-backend: 81 - podman build -t backend . 74 + _build-backend: 75 + @podman build -t backend . 82 76 83 77 # Create pod 84 78 [group("podman")] 85 - @create-pod: 79 + @_create-pod: 86 80 podman pod exists {{ pod_name }} ||\ 87 81 podman pod create \ 88 82 --name {{ pod_name }} \