File tree Expand file tree Collapse file tree 9 files changed +1316
-55
lines changed Expand file tree Collapse file tree 9 files changed +1316
-55
lines changed Original file line number Diff line number Diff line change 1
1
FROM nixos/nix
2
2
3
- COPY ./src /ihp
4
- WORKDIR /ihp
5
-
6
3
# Add build dependencies
7
- RUN nix-env -i cachix
4
+ RUN nix-env -f https://github.com/NixOS/nixpkgs/archive/54b4bb956f9891b872904abdb632cea85a033ff2.tar.gz -iA cachix
8
5
RUN cachix use digitallyinduced
9
6
7
+ COPY ./src /ihp
8
+ WORKDIR /ihp
9
+
10
10
# Build
11
- RUN nix- build -j auto --cores 0
11
+ RUN nix --extra-experimental-features "nix-command flakes" build -j auto --cores 0 .#optimized-prod-server
12
12
13
13
# Setup
14
14
ENV DATABASE_URL=postgres://benchmarkdbuser:benchmarkdbpass@tfb-database:5432/hello_world
Original file line number Diff line number Diff line change
1
+ if ! has nix_direnv_version || ! nix_direnv_version 2.3.0; then
2
+ source_url " https://raw.githubusercontent.com/nix-community/nix-direnv/2.3.0/direnvrc" " sha256-Dmd+j63L84wuzgyjITIfSxSD57Tx7v51DMxVZOsiUD8="
3
+ fi
4
+
5
+ use flake . --impure --accept-flake-config
6
+
7
+ # Include .env file if it exists locally. Use the .env file to load env vars that you don't want to commit to git
8
+ if [ -f .env ]
9
+ then
10
+ set -o allexport
11
+ source .env
12
+ set +o allexport
13
+ fi
14
+ # Add your env vars here
15
+ #
16
+ # E.g. export AWS_ACCESS_KEY_ID="XXXXX"
Original file line number Diff line number Diff line change 1
- import Prelude
2
- :def source readFile
3
- :source build/ihp-lib/applicationGhciConfig
1
+ :set -XNoImplicitPrelude
2
+ :def loadFromIHP \file -> (System.Environment.getEnv "IHP_LIB") >>= (\ihpLib -> readFile (ihpLib <> "/" <> file))
3
+ :loadFromIHP applicationGhciConfig
4
+ import IHP.Prelude
Original file line number Diff line number Diff line change 1
1
.DS_Store
2
- .envrc
3
2
.idea
4
3
tmp
5
4
result
17
16
del
18
17
static /prod. *
19
18
Config /client_session_key.aes
19
+
20
+ .devenv *
21
+ devenv.local.nix
22
+ .direnv
23
+ .env
Original file line number Diff line number Diff line change 1
- ifneq ($(wildcard IHP/.* ) ,)
2
- IHP = IHP/lib/IHP
3
- else
4
- IHP = $(shell dirname $$(which RunDevServer ) ) /../lib/IHP
5
- endif
6
-
7
- include ${IHP}/Makefile.dist
8
-
9
1
CSS_FILES += ${IHP}/static/vendor/bootstrap.min.css
10
2
CSS_FILES += ${IHP}/static/vendor/flatpickr.min.css
11
3
@@ -19,3 +11,5 @@ JS_FILES += ${IHP}/static/vendor/morphdom-umd.min.js
19
11
JS_FILES += ${IHP}/static/vendor/turbolinks.js
20
12
JS_FILES += ${IHP}/static/vendor/turbolinksInstantClick.js
21
13
JS_FILES += ${IHP}/static/vendor/turbolinksMorphdom.js
14
+
15
+ include ${IHP}/Makefile.dist
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments