Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is the local server required when using Parse? #45

Closed
CrabDude opened this issue Jan 25, 2016 · 1 comment
Closed

Is the local server required when using Parse? #45

CrabDude opened this issue Jan 25, 2016 · 1 comment

Comments

@CrabDude
Copy link

After "Setup" with the following /src/lib/config.js:

module.exports = {
  PARSE: {
    APP_ID: '...',
    REST_API_KEY: '...',
    SESSION_TOKEN_KEY: 'SESSION_TOKEN_KEY'
  },
  backend: {
    parse: true,
    hapiLocal: false,
    hapiRemote: false
  }
}

Running the iOS app in Xcode fails with the following error:

Could not connect to development server.

Ensure the following:
- Node Server is running and available on the same network - run 'npm start' from react-native root
- Node server URL is correctly set in AppDelegate

URL: http://localhosts/index.ios.bundle?platform=ios&dev=true

So, 4 things (EDIT: 5 things):

  1. Obviously it's not running, because I thought / it seemed it was possible to run the app using only Parse for the backend.
  2. I didn't see anything in "Setup" about updating AppDelegate; I do see mention of it in the "Continuous Integration" steps.
  3. The default / original value used in AppDelegate is localhosts. Is that a typo?
  4. Is it possibly to run this without the local server using only Parse?
  5. Also, switching to the automatically generated "pre-bundled file on disk" results in a successful build, with no error, but a blank (black) screen.

EDIT: Added 5th point above.
EDIT 2: Working just fine with local server AND Parse using localhost:8081 URL in AppDelegate instead of localhosts (assuming the latter is a typo).

@CrabDude
Copy link
Author

It seems the answer is, "Obviously, yes." and that this isn't really the issue I ran into, since the server is started automatically in the Build/Run steps. It's also obviously not mentioned in "Setup" because you don't have to run it manually.

It seems the issue I ran into was just due to the default localhosts instead of localhost:8081 typo, which generated an error message that lead me to believe the server hadn't been started and needed to be started manually.

Closing & opening separate issue for typo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant