Skip to content

Instantly share code, notes, and snippets.

View parsa-asgari's full-sized avatar

Parsa Asgari parsa-asgari

View GitHub Profile
@parsa-asgari
parsa-asgari / Jenkinsfile
Created February 20, 2022 06:23
simple Jenkinsfile using Docker and Django
node{
git branch: "master", url: "http://192.168.100.185:3000/parsa/Django_cicd"
stage ('Build the Docker image') {
sh "echo building the image..."
sh "docker build --tag django_test:latest ."
sh "echo building image complete."
}
@parsa-asgari
parsa-asgari / config.toml
Last active February 19, 2022 08:16
simple gitlab-runner config.toml for shell docker
concurrent = 1
check_interval = 0
[session_server]
session_timeout = 1800
[[runners]]
name = "YOUR_HOSTNAME"
url = "http://192.168.100.140/"
token = "YOUR_TOKEN"
@parsa-asgari
parsa-asgari / gitlab-ci.yml
Created February 13, 2022 11:48
Simple working gitlab-ci.yml for my django_test project
stages: # List of stages for jobs, and their order of execution
- build
- deploy
build-job: # This job runs in the build stage, which runs first.
stage: build
script:
- echo "building the image..."
- docker build --tag django_test:latest .
- echo "building image complete."
@parsa-asgari
parsa-asgari / dockerfile
Created February 13, 2022 11:46
sample dockerfile for django api
FROM ubuntu:latest
RUN apt-get update && apt-get install -y \
git \
python3 \
python3-pip
RUN pip3 install django djangorestframework tzdata
ENV LC_ALL C.UTF-8
ENV LANG C.UTF-8
WORKDIR /app
COPY . /app
@parsa-asgari
parsa-asgari / spark_numpy.py
Created November 17, 2018 08:23 — forked from koverholt/spark_numpy.py
Simple Numpy example in Spark
import numpy as np
from pyspark import SparkContext
from pyspark import SparkConf
conf = SparkConf()
conf.setMaster("spark://<HOSTNAME>:7077")
conf.setAppName("NumpyMult")
sc = SparkContext(conf=conf)
@parsa-asgari
parsa-asgari / cyb
Created September 18, 2018 15:17 — forked from b-coimbra/cyb
cyberpunk learning resources
**LEARNING**
http://cybrary.it/
http://n0where.net/
http://www.offensive-security.com/metasploit-unleashed
http://resources.infosecinstitute.com/
http://www.windowsecurity.com/articles-tutorials/
http://www.sans.org/reading-room/
https://www.corelan.be/index.php/articles/
http://opensecuritytraining.info/Training.html