Skip to content

Commit

Permalink
chore: env_file test
Browse files Browse the repository at this point in the history
  • Loading branch information
bbearcookie committed Jan 1, 2024
1 parent 973565b commit 2109ad0
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 32 deletions.
57 changes: 32 additions & 25 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,39 +74,46 @@ jobs:

- name: Setting .env
run: |
echo "NODE_ENV=${{ secrets.NODE_ENV }}" >> .env
echo "PORT=${{ secrets.PORT }}" >> .env
echo "LOCAL_API_ENDPOINT=${{ secrets.LOCAL_API_ENDPOINT }}" >> .env
echo "DEPLOY_API_ENDPOINT=${{ secrets.DEPLOY_API_ENDPOINT }}" >> .env
echo "${{ secrets.EXPRESS_ENV_FILE }} >> .env"
echo "LOCAL_CLIENT_ENDPOINT=${{ secrets.LOCAL_CLIENT_ENDPOINT }}" >> .env
echo "DEPLOY_CLIENT_ENDPOINT=${{ secrets.DEPLOY_CLIENT_ENDPOINT }}" >> .env
echo "DEPLOY_CLIENT_ENDPOINT_LEGACY=${{ secrets.DEPLOY_CLIENT_ENDPOINT_LEGACY }}" >> .env
mv .env packages/slack/.env
cat packages/slack/.env
echo "LOCAL_REDIS_ENDPOINT=${{ secrets.LOCAL_REDIS_ENDPOINT }}" >> .env
echo "DEPLOY_REDIS_ENDPOINT=${{ secrets.DEPLOY_REDIS_ENDPOINT }}" >> .env
echo "DEPLOY_REDIS_PASSWORD=${{ secrets.DEPLOY_REDIS_PASSWORD }}" >> .env
# - name: Setting .env
# run: |
# echo "NODE_ENV=${{ secrets.NODE_ENV }}" >> .env
# echo "PORT=${{ secrets.PORT }}" >> .env
# echo "LOCAL_API_ENDPOINT=${{ secrets.LOCAL_API_ENDPOINT }}" >> .env
# echo "DEPLOY_API_ENDPOINT=${{ secrets.DEPLOY_API_ENDPOINT }}" >> .env

echo "SNS_API_ENDPOINT=${{ secrets.SNS_API_ENDPOINT }}" >> .env
# echo "LOCAL_CLIENT_ENDPOINT=${{ secrets.LOCAL_CLIENT_ENDPOINT }}" >> .env
# echo "DEPLOY_CLIENT_ENDPOINT=${{ secrets.DEPLOY_CLIENT_ENDPOINT }}" >> .env
# echo "DEPLOY_CLIENT_ENDPOINT_LEGACY=${{ secrets.DEPLOY_CLIENT_ENDPOINT_LEGACY }}" >> .env

echo "SLACK_API_ENDPOINT=${{ secrets.SLACK_API_ENDPOINT }}" >> .env
echo "SLACK_HOOK_ENDPOINT=${{ secrets.SLACK_HOOK_ENDPOINT }}" >> .env
echo "SLACK_BOT_TOKEN=${{ secrets.SLACK_BOT_TOKEN }}" >> .env
echo "SLACK_SIGNING_SECRET=${{ secrets.SLACK_SIGNING_SECRET }}" >> .env
# echo "LOCAL_REDIS_ENDPOINT=${{ secrets.LOCAL_REDIS_ENDPOINT }}" >> .env
# echo "DEPLOY_REDIS_ENDPOINT=${{ secrets.DEPLOY_REDIS_ENDPOINT }}" >> .env
# echo "DEPLOY_REDIS_PASSWORD=${{ secrets.DEPLOY_REDIS_PASSWORD }}" >> .env

echo "DB_DATABASE=${{ secrets.DB_DATABASE }}" >> .env
echo "LOCAL_DB_USERNAME=${{ secrets.LOCAL_DB_USERNAME }}" >> .env
echo "LOCAL_DB_PASSWORD=${{ secrets.LOCAL_DB_PASSWORD }}" >> .env
# echo "SNS_API_ENDPOINT=${{ secrets.SNS_API_ENDPOINT }}" >> .env

echo "DEPLOY_DB_HOST=${{ secrets.DEPLOY_DB_HOST }}" >> .env
echo "DEPLOY_DB_USERNAME=${{ secrets.DEPLOY_DB_USERNAME }}" >> .env
echo "DEPLOY_DB_PASSWORD=${{ secrets.DEPLOY_DB_PASSWORD }}" >> .env
# echo "SLACK_API_ENDPOINT=${{ secrets.SLACK_API_ENDPOINT }}" >> .env
# echo "SLACK_HOOK_ENDPOINT=${{ secrets.SLACK_HOOK_ENDPOINT }}" >> .env
# echo "SLACK_BOT_TOKEN=${{ secrets.SLACK_BOT_TOKEN }}" >> .env
# echo "SLACK_SIGNING_SECRET=${{ secrets.SLACK_SIGNING_SECRET }}" >> .env

echo "JWT_SECRET_KEY=${{ secrets.JWT_SECRET_KEY }}" >> .env
echo "JWT_EXPIRES_IN=${{ secrets.JWT_EXPIRES_IN }}" >> .env
# echo "DB_DATABASE=${{ secrets.DB_DATABASE }}" >> .env
# echo "LOCAL_DB_USERNAME=${{ secrets.LOCAL_DB_USERNAME }}" >> .env
# echo "LOCAL_DB_PASSWORD=${{ secrets.LOCAL_DB_PASSWORD }}" >> .env

mv .env packages/slack/.env
cat packages/slack/.env
# echo "DEPLOY_DB_HOST=${{ secrets.DEPLOY_DB_HOST }}" >> .env
# echo "DEPLOY_DB_USERNAME=${{ secrets.DEPLOY_DB_USERNAME }}" >> .env
# echo "DEPLOY_DB_PASSWORD=${{ secrets.DEPLOY_DB_PASSWORD }}" >> .env

# echo "JWT_SECRET_KEY=${{ secrets.JWT_SECRET_KEY }}" >> .env
# echo "JWT_EXPIRES_IN=${{ secrets.JWT_EXPIRES_IN }}" >> .env

# mv .env packages/slack/.env
# cat packages/slack/.env

- run: yarn
- run: yarn slack test
14 changes: 7 additions & 7 deletions .github/workflows/setup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ jobs:

- run: ls -al

- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 18.x
cache: yarn
# - name: Setup Node
# uses: actions/setup-node@v3
# with:
# node-version: 18.x
# cache: yarn

- run: yarn
- run: yarn web build
# - run: yarn
# - run: yarn web build

0 comments on commit 2109ad0

Please sign in to comment.