Configure Amazon linux workspace for web development

  1. Login in to your workspace using Amazon workspace client application. The application can be download from link - https://clients.amazonworkspaces.com/
$ whoami
$ uname -a
$ sudo amazon-linux-extras install java-openjdk11
$ sudo alternatives --config java
 Add PostgreSQL Yum Repository$ sudo tee /etc/yum.repos.d/pgdg.repo<<EOF
[pgdg13]
name=PostgreSQL 13 for RHEL/CentOS 7 - x86_64
baseurl=https://download.postgresql.org/pub/repos/yum/13/redhat/rhel-7-x86_64
enabled=1
gpgcheck=0
EOF
Run system update
$ sudo yum update
Install PostgreSQL
$ sudo yum install postgresql13 postgresql13-server
Initialize the PostgreSQL Database
$ sudo /usr/pgsql-13/bin/postgresql-13-setup initdb
Enable and Start PostgreSQL Service
$ sudo systemctl start postgresql-13
$ sudo systemctl enable postgresql-13
$ sudo systemctl status postgresql-13
Change os user postgres password
$ sudo passwd postgres
change the Admin database password
$ sudo su - postgres
$ psql -c "ALTER USER postgres WITH PASSWORD 'your-password';"
Permit login to database through username and password instead of peer. (Optional)
$ sudo vim /var/lib/pgsql/13/data/pg_hba.conf
# TYPE DATABASE USER ADDRESS METHOD
# "local" is for Unix domain socket connections only
local all all scram-sha-256
# IPv4 local connections:
host all all 0.0.0.0/0 scram-sha-256
# IPv6 local connections:
host all all ::1/128 scram-sha-256
# Allow replication connections from localhost, by a user with the
# replication privilege.
local replication all peer
host replication all 127.0.0.1/32 scram-sha-256
host replication all ::1/128 scram-sha-256
Allow postgresql-server to listen all ip address (Optional)
$sudo vim /var/lib/pgsql/13/data/postgresql.conf
listen_address='*'
Restart services and check the version
$ sudo systemctl restart postgresql-13
$ psql -V
$ curl -sL https://rpm.nodesource.com/setup_16.x | sudo -E bash -
$ sudo yum install -y nodejs
$ node -v
$ sudo rpm --import https://packages.microsoft.com/keys/microsoft.asc
$ sudo sh -c 'echo -e "[code]\nname=Visual Studio Code\nbaseurl=https://packages.microsoft.com/yumrepos/vscode\nenabled=1\ngpgcheck=1\ngpgkey=https://packages.microsoft.com/keys/microsoft.asc" > /etc/yum.repos.d/vscode.repo'
$ sudo yum update
$ sudo yum install code
$ code -v
$ cd ~/Download
$ wget https://www.eclipse.org/downloads/download.php?file=/oomph/epp/2021-12/R/eclipse-inst-jre-linux64.tar.gz
$ tar -xvf eclipse-inst-jre-linux64.tar.gz
$ chmod -R eclipse-installer
$ cd eclipse-installer/
$ ./eclipse-inst

--

--

--

System Administrator and Full stack web developer.

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

READ/DOWNLOAD$) Analysis and Design of Energy Syst

How to make your python code run faster

How to handle the schema change ?

Developing the right attitude for the life you want to lead…

How to create NFT contract on AZero to work with ArtZero?

Assert Exceptions in NUnit

Microsoft Azure vs AWS: The Cloud Comparison Guide [2017]

Day 34 — Unique Paths II

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
Himanshu Pratap

Himanshu Pratap

System Administrator and Full stack web developer.

More from Medium

Running Redis with resilience in Linux containers on Windows — Part 1

docker search redis

Notifications for failed cron jobs

How To Fork A Repository In Github

Installing and Setting up MongoDB on Linux