Connect Amplication server to GitHub
#
Connect Amplication server to GitHubAmplication already provides built-in integration with GitHub to push the generated application to a GitHub repository.
When running a local Amplication server you first need to configure the server to integrate with a new GitHub app, following the steps below.
info
When using the hosted service on https://app.amplication.com, the integration is pre-configured and you just need to follow this guide to sync your application with GitHub.
#
Create a new GitHub App- Go to https://github.com/settings/developers.
- Click on OAuth Apps.
- Click on Register a new application.
- Give the application any name.
- Set the Authorization callback URL URL to http://localhost:3001
info
In case you are hosting the Amplication server on any other address, use the specific address instead of http://localhost:3001
- Copy and save the client secret and client ID of your new GitHub application.
#
Configure Amplication server to work with the new GitHub appGo the ../packages/amplication-server/
Add a .env.local file in the root of the server directory
- Add the following content to the file
Replace [client_secret_here] with the client secret of the new GitHub application.
Replace [client_id_here] with the client ID of the new GitHub application.
Restart Amplication server.