-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.envrc
More file actions
54 lines (40 loc) · 2.64 KB
/
.envrc
File metadata and controls
54 lines (40 loc) · 2.64 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#! /bin/sh
# SPDX-FileCopyrightText: 2024 tokenflows <https://tokenflows.xyz/>
#
# SPDX-License-Identifier: Apache-2.0
# Paisano implements an API for organizing Nix code into folders. It then maps that folder structure into Flake
# outputs, once per system. To type outputs, an output type system is provided and traits (i.e. "abstract behaviour")
# may be implemented on them.
# Paisna file is sourced by direnv when entering the directory. The content below
# is pulled from: https://divnix.github.io/std/guides/envrc.html
## NOTE: Commmented out because this is a divnix:std target which the current project does not use.
## source "$(fetchurl "https://raw.githubusercontent.com/paisano-nix/direnv/main/lib" "sha256-XKqDMz+VtF8VSJ4yOok4mO1xxXUZbD1t2yC0JmEXrCI=")"
# Local configuarions.
#
# Read .envrc.local somewhere up the development tree. Note direnv will also read ~/.config/direnv/direnvrc if
# it exits.
#
# We can select which development environment is used by `direnv`. The default devshell is 'dev'. Power users
# can choose a different devshell target, overridding the default by defining DEVSHELL_TARGET in .envrc.local
# somewhere up the directory tree. See: /nix/std-example/devshells.nix.
source_up_if_exists .envrc.local
# Specify the default development shell overriding nix's 'default' in favour of the name 'dev'. It can be overridden
# in .envrc.local or ~/.config/direnv/direnvrc.
export DEVSHELL_TARGET=${DEVSHELL_TARGET:-default}
# When that variable is set, devshell will not display the menu that is executed on entrypoint.
export DEVSHELL_NO_MOTD=${DEVSHELL_NO_MOTD:-0}
export TFENV_CONFIG_SECRET_KEY_FILE=${ENV_CONFIG_SECRET_KEY_FILE:-"$HOME/.config/secrets/keys.txt"}
export TFENV_CONFIG_PROJECT_NAME=${ENV_CONFIG_PROJECT_NAME:-"yumiai-website"}
## export YUMIENV_CONFIG_DOCS_ROOT=""
export TFENV_CONFIG_DOCS_PORT=${ENV_CONFIG_DOCS_PORT:-8080}
export TFENV_GITHUB_BASEURL=github:tokenflows
# Must be signed into Tailscale for the following service to be accessible.
export TFENV_GITEA_BASEURL=https://gitea.org.yumi.ai/
export TFENV_GIT_BASEURL=$ENV_GITEA_BASEURL
# SOPS: Pulling in API Token Secrets, via readFile, is an impure operation. API Tokens are held in an encrypted JSON
# file in the project repository using SOPS. It is encrypted such that AGE, SSH, GPG keys can be used to
# decrypt the API Tokens. However to pull the secrets into a Nix Flake such that the secret keys are NOT put into
# the NIX store means flakes are impure.
## NOTE: Commmented out because this is a divnix:std target which the current project does not use.
## use envreload "//dev/shells/${DEVSHELL_TARGET}" //dev/configs
use flake . --impure