Skip to content

Instantly share code, notes, and snippets.

View Adeotan's full-sized avatar
🏠
Working from home

Adeotan Lambe Adeotan

🏠
Working from home
View GitHub Profile
@Adeotan
Adeotan / kubernetes.md
Created November 12, 2022 11:56 — forked from xmlking/kubernetes.md
Kubernetes Cheat Sheet

Kubernetes

Install

Prerequisites

  1. Bash v5+ checkout Upgrading Bash on macOS
  2. bash-completion@2

Install Docker and Kubernetes(k8s)

FROM python:3.6.4-slim-stretch
RUN apt-get update && apt-get install -y build-essential git time
RUN pip install https://anaconda.org/intel/tensorflow/1.6.0/download/tensorflow-1.6.0-cp36-cp36m-linux_x86_64.whl
RUN git clone https://github.com/tensorflow/models.git
ENV PYTHONPATH $PYTHONPATH:$HOME/models
WORKDIR $HOME/models/official/resnet/
RUN pip3 install -r ../requirements.txt
apiVersion: v1
kind: Pod
metadata:
name: stress-pod
spec:
containers:
- image: gcr.io/google-containers/stress:v1
args: ["-cpus", "48"]
name: stress-container
resources:
apiVersion: v1
kind: Pod
metadata:
name: tf-wide-deep-census-pod
spec:
containers:
- image: <insert-image>
command: ["/bin/sh"]
args: ["-c", "/usr/bin/time python ./wide_deep.py --model_type=wide_deep --train_epochs=500 --epochs_between_eval=500 --batch_size=32561"]
name: tf-wide-deep-census
FROM python:3.6-slim-stretch
RUN apt-get update && apt-get install -y git time
RUN pip install https://anaconda.org/intel/tensorflow/1.6.0/download/tensorflow-1.6.0-cp36-cp36m-linux_x86_64.whl
RUN git clone https://github.com/tensorflow/models.git
ENV PYTHONPATH $PYTHONPATH:$HOME/models
WORKDIR $HOME/models/official/wide_deep
RUN python ./data_download.py
FROM nvidia/cuda:9.0-cudnn7-runtime-ubuntu16.04
################################
# Install apt-get Requirements #
################################
# General
RUN apt-get update && \
apt-get install -y python3-pip cmake zlib1g-dev python3-tk python-opencv \
# Boost libraries
FROM coach-base:master as builder
# prep mujoco and any of its related requirements.
# Mujoco
RUN mkdir -p ~/.mujoco \
&& wget https://www.roboti.us/download/mjpro150_linux.zip -O mujoco.zip \
&& unzip -n mujoco.zip -d ~/.mujoco \
&& rm mujoco.zip
ARG MUJOCO_KEY
ENV MUJOCO_KEY=$MUJOCO_KEY
FROM coach-base:master as builder
# prep gym and any of its related requirements.
RUN pip3 install gym[atari,box2d,classic_control]==0.10.5
# add coach source starting with files that could trigger
# re-build if dependencies change.
RUN mkdir /root/src
COPY setup.py /root/src/.
COPY requirements.txt /root/src/.
apiVersion: v1
kind: Pod
metadata:
name: parsec-pod
spec:
containers:
# See https://github.com/Spirals-Team/benchmark-containers/tree/master/parsec-3.0 for more information on image.
- image: spirals/parsec-3.0
command: ["/bin/bash"]
# Change args to run the workload.