Skip to content

Instantly share code, notes, and snippets.

@tung1404
tung1404 / Django installations on Ubuntu.md
Created December 6, 2023 14:56 — forked from 101t/Django installations on Ubuntu.md
Quick Start with Django installations on Ubuntu

Django installations on Ubuntu

Installing Python in system

First step install dependencies.

sudo apt-get install git python-setuptools python-pip python-dev \
&& sudo apt-get install python3-pip python3-dev virtualenv

then install local envirement of Django project.

@tung1404
tung1404 / docker-compose.yml
Created November 7, 2023 04:41 — forked from benoitpetit/docker-compose.yml
complete Gitlab installation and a runner with docker
version: '4.5'
services:
# GITLAB
gitlab-web:
image: 'gitlab/gitlab-ce:latest'
restart: always
container_name: gitlab-web
hostname: '192.168.0.14'
environment:
@tung1404
tung1404 / Jest_GitLab_CI.md
Created November 7, 2023 04:32 — forked from rishitells/Jest_GitLab_CI.md
Setting up Jest tests and coverage in GitLab CI

Configuring Jest Tests in GitLab CI

1. Add GitLab CI configuration file in the root

In the root of your project, add .gitlab-ci.yml with the configuration below.

image: node:latest

stages:
@tung1404
tung1404 / opentracing.yaml
Created August 2, 2023 03:13 — forked from wshihadeh/opentracing.yaml
Tarefik opentracing
version: '3.7'
networks:
traefik:
external: true
services:
pink:
@tung1404
tung1404 / docker-compose.yml
Created August 1, 2023 04:17 — forked from pyrou/docker-compose.yml
Use https://traefik.me SSL certificates for local HTTPS without having to touch your /etc/hosts or your certificate CA.
version: '3'
services:
traefik:
restart: unless-stopped
image: traefik:v2.0.2
ports:
- "80:80"
- "443:443"
labels:
- "traefik.http.services.traefik.loadbalancer.server.port=8080"
@tung1404
tung1404 / .eslintignore
Created April 29, 2023 09:29 — forked from vdelacou/.eslintignore
React Vite Typescript Eslint
vite.config.ts
src/vite-env.d.ts
dist
@tung1404
tung1404 / .zshrc
Created April 14, 2023 03:07 — forked from pocin/.zshrc
Use conda+pyenv to manage python
# $ brew install pyenv #pay attention to caveats ($ brew info pyenv)
# $ brew install pyenv-virtualenv
# this goes into .zshrc
export PYENV_ROOT=/usr/local/var/pyenv
if which pyenv > /dev/null; then eval "$(pyenv init -)"; fi
if which pyenv-virtualenv-init > /dev/null; then eval "$(pyenv virtualenv-init -)"; fi
@tung1404
tung1404 / sqlite3mysql.py
Created November 3, 2022 01:58 — forked from techouse/sqlite3mysql.py
A simple Python 3 script to transfer the data from SQLite 3 to MySQL. Requires MySQL Connector/Python 2.0.4 or higher.
#!/usr/bin/env python3
import logging
import sqlite3
import sys
import re
from math import ceil
from os.path import realpath, isfile
import mysql.connector
from mysql.connector import errorcode
@tung1404
tung1404 / local-registry.md
Created July 18, 2022 01:43 — forked from trisberg/local-registry.md
Using a Local Registry with Minikube

Using a Local Registry with Minikube

Install a local Registry

These instructions include running a local registry accessible from Kubernetes as well as from the host development machine at registry.dev.svc.cluster.local:5000.

  1. Use the docker CLI to run the registry:2 container from Docker, listening on port 5000, and persisting images in the ~/.registry/storage directory.
@tung1404
tung1404 / nextjs-deploy.md
Created April 17, 2022 02:42 — forked from jjcodes78/nextjs-deploy.md
Deploying NEXTJS site with nginx + pm2

How to setup next.js app on nginx with letsencrypt

next.js, nginx, reverse-proxy, ssl

1. Install nginx and letsencrypt

$ sudo apt-get update
$ sudo apt-get install nginx letsencrypt

Also enable nginx in ufw