Skip to content

Instantly share code, notes, and snippets.

View ecampusdev's full-sized avatar

eCampuslearning-Dev ecampusdev

View GitHub Profile
@ecampusdev
ecampusdev / README.md
Created August 20, 2025 14:05 — forked from felipepodesta/README.md
Ubuntu Development Environment Setup Script

Ubuntu Dev Setup Script

I tend to setup and teardown my dev environments quite frequently. So I have created this setup.sh script to automate setting up the dev environment with my preferences.

This script -

  • Installs curl, git, net-tools, and tree.
  • Installs build-essential package which installs gcc, g++ and some other libs.
  • Installs the latest openjdk and maven.
  • Installs python3 and some required libraries (I use them pretty often).
  • Installs nodejs 12 globally. Then installs Node Version Manager and installs all LTS versions.
@ecampusdev
ecampusdev / example_usage.pp
Created April 27, 2025 18:33 — forked from yakatz/example_usage.pp
Manage System Git Config with Puppet
class myweb::sites::wiki_example_com {
wiki_base = '/var/www/sites/wiki.example.com'
include ::profile::gitconfig
profile::gitconfig::safe_directory {"${wiki_base}/code/mediawiki-1.35-LTS":}
vcsrepo { "${wiki_base}/code/mediawiki-1.35-LTS/":
ensure => latest,
provider => git,
source => 'git@gitlab.example.com:wiki/mediawiki-1.35-LTS.git',
@ecampusdev
ecampusdev / r_ubuntu_18_04.sh
Created April 25, 2025 23:32 — forked from ElToro1966/r_ubuntu_18_04.sh
Install R and RStudio on Ubuntu 18.04 with essential libraries for data science. Based on pachamaltese/r_ubuntu_17_10.sh (for Ubuntu 17.10). Note: You need to make sure the default library location - /usr/local/lib/R/site-packages - is writable .
# Install R
sudo apt update
sudo apt install gdebi libxml2-dev libssl-dev libcurl4-openssl-dev libopenblas-dev r-base r-base-dev
# Install RStudio
cd ~/Downloads
wget https://download1.rstudio.org/desktop/bionic/amd64/rstudio-1.2.5001-amd64.deb
sudo gdebi rstudio-1.2.5001-amd64.deb
printf '\nexport QT_STYLE_OVERRIDE=gtk\n' | sudo tee -a ~/.profile
@ecampusdev
ecampusdev / multiple.conf
Created January 30, 2025 12:40 — forked from jurchiks/multiple.conf
Nginx config for multiple hosts, multi-user, multi-project
server {
listen 80;
server_name ~^(?<project>.+)\.(?<username>.+)\.hhvm\.dyninno\.net$;
if (!-d /home/$username/public_html/$project) {
return 405;
break;
}
set $root /home/$username/public_html/$project;
@ecampusdev
ecampusdev / guide.md
Created January 30, 2025 04:36 — forked from jd-apprentice/guide.md
# Dockerize a database + DBeaver

How to build and run our containers.

First create a .env file with the following structure (names are like this because i'm using postgres)

POSTGRES_CONTAINER_NAME=
POSTGRES_CONTAINER_IMAGE_NAME=

postgres_USER=
postgres_PASS=
@ecampusdev
ecampusdev / .circleci-config.yml
Created September 24, 2024 11:08 — forked from markgono/.circleci-config.yml
An example circleci/config.yml file
defaults: &defaults
working_directory: ~/gatsby/
node: &node
docker:
- image: circleci/node:12
alpine: &alpine
docker:
- image: markgono/alpine-vps-worker
#!/bin/bash
# docker installation on Ubunutu 16.04+
# source https://www.dockerfile.de/docker-tutorial-installation
# remove any old docker
sudo apt-get remove docker docker-engine docker.io
# install prerequisites
sudo apt-get install \
apt-transport-https \
@ecampusdev
ecampusdev / keepass.md
Created September 4, 2024 11:01 — forked from Rapptz/keepass.md
Setting up KeePass

Setting Up KeePass

I frequently see discussions around which password manager to use. I personally use [KeePass][main]. This is an open source program that allows you to have control in your data. The database format is encrypted so as long as you keep your master password secure, the chance of someone getting access to your passwords is practically zero.

This document is just meant as a signpost to steer you in the right direction of how to set up KeePass across multiple operating systems and have your file synced in the cloud all while paying $0 and not having to set up a single server to do so.

Why KeePass?

You can skip this if you don't care

@ecampusdev
ecampusdev / Dockerfile
Last active July 16, 2025 03:26 — forked from WuSiYu/Dockerfile
A "full" ubuntu-server development environment docker image
FROM ubuntu:latest
LABEL maintainer="SiYu Wu <wu.siyu@hotmail.com>"
ENV DEV_USER=user
ENV UID=1000
ENV GID=1000
ENV DEF_PASSWD=password
ENV TZ=Asia/Shanghai
ENV LANG=en_US.UTF-8
@ecampusdev
ecampusdev / .gitattributes
Created September 4, 2024 09:02 — forked from Voonder/.gitattributes
Sample of git config file (Example .gitconfig, .gitattributes, .gitignore)
# Auto detect text files and perform LF normalization
* text=auto
# Documents
*.doc diff=astextplain
*.DOC diff=astextplain
*.docx diff=astextplain
*.DOCX diff=astextplain
*.dot diff=astextplain
*.DOT diff=astextplain