Add Deployment
You can connect your existing Git repos (from any git provider such Github, Gitlab, Bitbucket etc) to InstaWP.
Adding a Deployment
To add a new deployment to InstaWP, use the Deployments tab. Click on Add New to connect an existing repository.
- Repo Type - Public for public repo and Private for private repos.
- Repo URL - Add the URL to your repo (for example - https://github.com/yourcompany/yourplugin)
- Branch - Mention the branch which this deployment points to (more on this later)
- Destination Folder - The folder where your respository content will be download to.
- Post Deployment Commands - Shell commands which will be run after the git repository is cloned (for example,
composer install
,npm install
,npm run dev
,wp config set WP_DEBUG true --raw
)
Click on "Add" to add the new Deployment.
SSH Key Pair
In case you are connecting a Private repository, you will be asked to generate a SSH Key pair.
Click on "+ Generate New" and you will get a public key, copy the key and add it to your Git repository.
Post-deployment Commands for Private Repos
If you need to download a composer or npm package during the post-deployment commands, use the following trick:
GIT_SSH_COMMAND="ssh -i /tmp/`echo whoami`-git-key -o IdentitiesOnly=yes" composer install
Updated 2 months ago