Skip to content

Commit

Permalink
added process.env in config.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
akyriako committed Jul 8, 2024
1 parent ab8ab0d commit bbc32ce
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 11 deletions.
17 changes: 10 additions & 7 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,19 @@ jobs:
run: npm install

- name: Build site
env:
TYPESENSE_HOST: ${{ vars.TYPESENSE_HOST }}
run: npm run build

- name: Say Hi!
env:
TYPESENSE_PROTOCOL: ${{ vars.TYPESENSE_PROTOCOL }}
TYPESENSE_HOST: ${{ vars.TYPESENSE_HOST }}
TYPESENSE_PORT: ${{ vars.TYPESENSE_PORT }}
TYPESENSE_API_KEY: ${{ secrets.TYPESENSE_API_KEY }}
run: |
echo "Typesense target is $TYPESENSE_PROTOCOL://$TYPESENSE_HOST:$TYPESENSE_PORT"
run: npm run build

# - name: Say Hi!
# env:
# TYPESENSE_PROTOCOL: ${{ vars.TYPESENSE_PROTOCOL }}
# TYPESENSE_HOST: ${{ vars.TYPESENSE_HOST }}
# TYPESENSE_PORT: ${{ vars.TYPESENSE_PORT }}
# TYPESENSE_API_KEY: ${{ secrets.TYPESENSE_API_KEY }}
# run: |
# echo "Typesense target is $TYPESENSE_PROTOCOL://$TYPESENSE_HOST:$TYPESENSE_PORT"

8 changes: 4 additions & 4 deletions docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -224,12 +224,12 @@ const config: Config = {
typesenseServerConfig: {
nodes: [
{
host: "docs-search.hypelens.de",
port: 80,
protocol: "http",
host: process.env.TYPESENSE_HOST,
port: process.env.TYPESENSE_PORT,
protocol: process.env.TYPESENSE_PROTOCOL,
},
],
apiKey: "j2Q51UsLuh9guYtc4x147Mv5X74g4iSI",
apiKey: process.env.TYPESENSE_API_KEY,
},

// Optional: Typesense search parameters: https://typesense.org/docs/0.24.0/api/search.html#search-parameters
Expand Down

0 comments on commit bbc32ce

Please sign in to comment.