Skip to main content
Version: current

6. Code repository

The last step is to deploy your changes. For that our cloud platform will need access to your code repository. We use an SSH key for access and web hooks to allow us to watch for code changes.

We currently support GitHub, BitBucket or GitLab.

We'll only need read access to your repo.

1. Getting your details#

You can get your SSH key and web hook details using dcloud.

Simply run the following command from a terminal window when logged into dcloud:

dcloud repo -i

GitHub#

Adding an SSH Key#

  • Go to https://github.com/<accountName>/<repoName>/settings/keys/new
  • Add your key

GitHub SSH access

Adding a web hook#

  • Go to https://github.com/<accountName>/<repoName>/settings/hooks/new
  • Add the webhook provided by dcloud repo:list -i.

GitHub WebHook


Bitbucket#

Adding an SSH Key#

  • Go to https://bitbucket.org/<accountName>/<repoName>/admin/access-keys/
  • Add your key

BitBucket SSH access - add

Adding a web hook#

Coming soon


GitLab#

Adding an SSH Key#

  • Go to https://gitlab.com/<accountName>/<repoName>/-/settings/repository
  • Open the Deploy keys section
  • Add your key

GitLab SSH access

Adding a web hook#

Coming soon

Setup Complete#

That's everything done. You're now ready to start using Deity Cloud. View the full list of dcloud commands.

Next step, deploy your code.


2. Check your connection#

To check your repository and cloud instance are linked run the following command. Your repo URL should be returned

dcloud repo

3. View your builds#

Every time you push a commit, a build is triggered. These builds are not 'deployed' automatically but are made available to deploy once they are finished.

To view your builds run

dcloud build:list

4. Deploy your code#

To deploy a build you can run the command

dcloud deployment:run [buildId] [environmentName]

More details can be found here

Ask the community. #help

If you can't find what you're looking for, the answer might be on our community slack channel. Our team keep a close eye on this and will usually get back to you within a few hours, if not straight away. If you haven't created an account yet please sign up here slack.deity.io.

Stay up to date

Do you want to be informed when we release new features or fixes? Sign up to our newsletter to stay in the loop.