# Delete all containers
docker rm $(docker ps -aq)
# Delete all images
docker rmi $(docker images -q)
# Delete all untagged images
docker rmi $(docker images -q --filter "dangling=true")
References:
# Freelancing Reviews Samples | |
======================================================================= | |
**** | |
======================================================================= | |
## Buyer Reviews to Sellers | |
======================================================================= |
apiVersion: v1 | |
kind: Pod | |
metadata: | |
name: {{ .Release.Name }}-post-upgrade-hook | |
labels: | |
app.kubernetes.io/name: {{ .Release.Name }} | |
annotations: | |
"helm.sh/hook": "post-upgrade" | |
"helm.sh/hook-delete-policy": "hook-succeeded" | |
"sidecar.istio.io/inject": "false" |
echo ' | |
[sensu] | |
name=sensu | |
baseurl=https://sensu.global.ssl.fastly.net/yum/6/x86_64/ | |
gpgcheck=0 | |
enabled=1 | |
' | tee -a /etc/yum.repos.d/sensu.repo |
#!/bin/bash | |
export NODE_VERSION=14.16.1 | |
export NODE_DOWNLOAD_URL=https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION-linux-x64.tar.xz | |
export NODE_INSTALL=/opt/node | |
export PATH=$NODE_INSTALL/bin:$PATH | |
sudo mkdir $NODE_INSTALL | |
sudo chown -R ${USER} $NODE_INSTALL |
'use strict'; | |
/* | |
Thanks to https://gist.github.com/vgeshel/1dba698aed9e8b39a464 | |
*/ | |
console.log('Loading function'); | |
const aws = require('aws-sdk'); | |
const s3 = new aws.S3({ apiVersion: '2006-03-01' }); |
CREATE USER r_only_user identified by 'password'; | |
GRANT SELECT, SHOW VIEW, PROCESS, REPLICATION CLIENT ON *.* TO 'r_only_user'@'%' IDENTIFIED BY 'password'; | |
GRANT SELECT, SHOW VIEW, PROCESS, REPLICATION CLIENT ON *.* TO 'r_only_user'@'localhost' IDENTIFIED BY 'password'; | |
FLUSH PRIVILEGES; |
-- Create a group | |
CREATE ROLE readaccess; | |
-- Grant access to existing tables | |
GRANT USAGE ON SCHEMA public TO readaccess; | |
GRANT SELECT ON ALL TABLES IN SCHEMA public TO readaccess; | |
-- Grant access to future tables | |
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO readaccess; |
# Delete all containers
docker rm $(docker ps -aq)
# Delete all images
docker rmi $(docker images -q)
# Delete all untagged images
docker rmi $(docker images -q --filter "dangling=true")
References:
#!/bin/bash | |
sudo yum update -y | |
sudo yum install -y netstat git rubygems gcc kernel-devel make perl | |
sudo yum install -y java-1.8.0-openjdk java-1.8.0-openjdk-devel maven | |
sudo gem install sass | |
cd /tmp |
#!/bin/bash | |
mkdir git-repo | |
cd git-repo | |
git init | |
touch my_code.sh | |
git add my_code.sh | |
echo "echo Hello" > my_code.sh | |
git commit -am 'initial' | |
git checkout -b new_branch | |
echo "echo \"Hello World\"" > my_code.sh |