Skip to content

Instantly share code, notes, and snippets.

View ashwoods's full-sized avatar

Ashley Camba ashwoods

View GitHub Profile
#!/bin/bash
#
# PostgreSQL Backup Script Ver 1.0
# http://autopgsqlbackup.frozenpc.net
# Copyright (c) 2005 Aaron Axelsen <[email protected]>
#
# This script is based of the AutoMySQLBackup Script Ver 2.2
# It can be found at http://sourceforge.net/projects/automysqlbackup/
#
# The PostgreSQL changes are based on a patch agaisnt AutoMySQLBackup 1.9

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)
sudo apt-get install ruby-dev
sudo gem install rdoc
sudo gem install guard
sudo gem install guard-livereload
@ashwoods
ashwoods / install-teamcity.md
Last active March 8, 2024 23:10 — forked from sandcastle/install-teamcity.md
Install TeamCity 10.0.2 on Debian/Ubuntu with Nginx

Install

Follow the steps below to install Team City 10.0.2 on Debian/Ubuntu with Nginx as the proxy for port 80.

Requirements:

  • curl
  • configure utf-8 locale of your choice (recommended)

Install Team City:

@ashwoods
ashwoods / cx_oracle.md
Created May 2, 2017 09:13 — forked from kimus/cx_oracle.md
Installing python cx_oracle on Ubuntu

First of all, it just seems like doing anything with Oracle is obnoxiously painful for no good reason. It's the nature of the beast I suppose. cx_oracle is a python module that allows you to connect to an Oracle Database and issue queries, inserts, updates..usual jazz.

Linux

Step 1:

sudo apt-get install build-essential unzip python-dev libaio-dev

Step 2. Click here to download the appropriate zip files required for this. You'll need:

@ashwoods
ashwoods / check-qemu-binfmt.sh
Created December 14, 2021 17:30 — forked from ArturKlauser/check-qemu-binfmt.sh
Building Multi-Architecture Docker Images With Buildx
#!/bin/bash
# (c) 2020 [email protected]
# SPDX-License-Identifier: Apache-2.0 OR MIT
#
# This script checks if all software requirements are met in a Linux environment
# in order to use 'docker buildx' to build multi-architecture images.
# For more information see:
# https://nexus.eddiesinentropy.net/2020/01/12/Building-Multi-architecture-Docker-Images-With-Buildx/
function error() {