Skip to content

Instantly share code, notes, and snippets.

View Mazafard's full-sized avatar
🏠
paaah!

Mohammadreza Asadollahifard Mazafard

🏠
paaah!
View GitHub Profile
@stepankuzmin
stepankuzmin / README.md
Created January 4, 2019 10:22
Gitlab AutoDevops on DigitalOcean k8s
@amirasaran
amirasaran / rtl.css
Last active July 24, 2022 13:34
Django JET admin RTL (For persian and arabic ,...)
@import url("../fonts/css/fontiran.css");
html {
direction: rtl;
font-family: IRANSans;
}
.sidebar {
right: 0 !important;
left: auto !important;
@MetalArend
MetalArend / swarm.yml
Last active November 18, 2024 01:43
Run a GitLab Runner on your Swarm
version: '3.4'
secrets:
# Find your registration token at: "Your project" > "Settings" > "CI/CD" > "Runners settings" > "Specific Runners" (look for registration token)
# Register it as `GITLAB_REGISTRATION_TOKEN`: `docker secret create GITLAB_REGISTRATION_TOKEN YOUR_REGISTRATION_TOKEN`
GITLAB_REGISTRATION_TOKEN:
external: true
# Find your personal access token at: "Your user account" > "Settings" > "Access Tokens" > "Create personal access token" (for api)
# Register it as `GITLAB_PERSONAL_ACCESS_TOKEN`: `docker secret create GITLAB_PERSONAL_ACCESS_TOKEN <YOUR ACCESS TOKEN>`
@Nagyman
Nagyman / workflows-in-django.md
Last active November 20, 2024 01:08
Workflows in Django

Workflows (States) in Django

I'm going to cover a simple, but effective, utility for managing state and transitions (aka workflow). We often need to store the state (status) of a model and it should only be in one state at a time.

Common Software Uses

  • Publishing (Draft->Approved->Published->Expired->Deleted)