Skip to content

Commit

Permalink
Merge pull request #335 from hackforla/dev
Browse files Browse the repository at this point in the history
Updating master with dev
  • Loading branch information
sellnat77 authored Mar 1, 2020
2 parents a3fb483 + 596538a commit 9c49195
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/Continuous_Delivery.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ jobs:
run: export CI=true && npm run test -- --coverage
env:
MAPBOX_TOKEN: ${{ secrets.MAPBOX_TOKEN }}
DB_URL: ${{ secrets.DB_URL }}
# DISABLING DEPLOYMENT TO PRESERVE "PRODUCTION"
- name: Deploy to GH pages
uses: JamesIves/github-pages-deploy-action@master
Expand All @@ -32,4 +33,4 @@ jobs:
BASE_BRANCH: master # The branch the action should deploy from.
BRANCH: gh-pages # The branch the action should deploy to.
FOLDER: dist # The folder the action should deploy.
BUILD_SCRIPT: echo REACT_APP_MAPBOX_TOKEN=${{secrets.MAPBOX_TOKEN}} > .env && npm rebuild node-sass && npm install && npm run-script build # The build script the action should run prior to deploying.
BUILD_SCRIPT: echo REACT_APP_MAPBOX_TOKEN=${{secrets.MAPBOX_TOKEN}} && echo DB_URL=${{secrets.DB_URL}} > .env && npm rebuild node-sass && npm install && npm run-script build # The build script the action should run prior to deploying.
1 change: 1 addition & 0 deletions .github/workflows/Continuous_Integration_Frontend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,4 @@ jobs:
run: npm run test -- --coverage
env:
MAPBOX_TOKEN: ${{ secrets.MAPBOX_TOKEN }}
DB_URL: ${{ secrets.DB_URL }}
3 changes: 2 additions & 1 deletion src/redux/rootSaga.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import {
getDataFailure,
} from './reducers/data';

const pinUrl = `http://${process.env.DB_URL}/pins`;
const getState = (state, slice) => state[slice];

function* getData() {
Expand All @@ -29,7 +30,7 @@ function* getData() {
};

try {
const response = yield call(axios.post, process.env.DB_URL, options);
const response = yield call(axios.post, pinUrl, options);
const { data } = response;
yield put(getDataSuccess(data));
} catch (e) {
Expand Down

0 comments on commit 9c49195

Please sign in to comment.