This article will help readers to set up PostgreSQL on Ubuntu Server and be able to connect remotely.

Instructions

Before start reading this article I assume you are familiar with basic Linux commands and putty is installed on your pc.

  • Open putty and connect with your remote server using your credentials.

This article is about setting up the development environment for GoLang.

Instructions

  1. Download Go and install
  2. Update your Visual Studio Code to the latest edition or install the latest edition.
  3. Install the Go extension for vscode from here.
  4. Open your Go project in vscode.
  5. Click install/install all if any popup message is shown. vscode will automatically download all necessary dependencies.
  6. Navigate to your project folder and check for a file named ‘go.mod’.
  7. If ‘go.mod’ is not found then use go mod init command from Powershell.
  8. i.e: go mod init zachai.xyz/verify-api
  9. go.mod file will be created with reference to all used dependencies.
  10. use go get -u github.com/golang/dep/cmd/dep to download dependencies.
  11. use go build to build your project.
  12. and run your project.
  13. Happy coding…😍😍😍

This article is to enable auto migration in GoLang with integration with GORM in up-down approach.

Create migration CLI

To enable auto migration in Go with GORM install golang-migrate.

  • Run following commands:
$ go get -u -d github.com/golang-migrate/migrate/cmd/migrate
$ cd $GOPATH/src/github.com/golang-migrate/migrate/cmd/migrate
$ git checkout $TAG # e.g. v4.8.0
$ go build -tags 'postgres' -ldflags="-X…

Faisal AL Mahmud

Every lie we tell incurs a debt to the truth. Sooner or later, that debt is paid.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store