Skip to content

Instantly share code, notes, and snippets.

View ops-gaurav's full-sized avatar
:octocat:
may the forks be with you

Gaurav Sharma ops-gaurav

:octocat:
may the forks be with you
View GitHub Profile
@ops-gaurav
ops-gaurav / deploy-keys.md
Created May 6, 2021 08:29 — forked from holmberd/deploy-keys.md
Setup GitHub repository SSH deploy keys

Setup GitHub repository SSH deploy keys

  1. Create GitHub repository in github and save the SSH repository url

  2. Init git on server in code directory

  • git init
  1. Create SSH keys on the server
  • ssh-keygen -t rsa -b 4096 -C your@email.here
  • Rename the key that doesn't end with .pub to repo-name.deploy.pem
@ops-gaurav
ops-gaurav / README.md
Created March 1, 2021 09:40 — forked from mosquito/README.md
Add doker-compose as a systemd unit

Docker compose as a systemd unit

Create file /etc/systemd/system/docker-compose@.service. SystemD calling binaries using an absolute path. In my case is prefixed by /usr/local/bin, you should use paths specific for your environment.

[Unit]
Description=%i service with docker compose
Requires=docker.service
After=docker.service