Last active
April 1, 2019 18:26
-
-
Save milesmatthias/62d34b05831bfe2ce8762f3795b002ca to your computer and use it in GitHub Desktop.
miles dev image
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PROJECT= | |
CLUSTER= | |
# build ox-cluster-poller | |
docker build -t gcr.io/$PROJECT/miles-dev-image . | |
docker push gcr.io/$PROJECT/miles-dev-image | |
# Uncomment below for dev | |
gcloud container clusters get-credentials $CLUSTER \ | |
--zone us-central1-a --project $PROJECT | |
kubectl create namespace miles-spin-dev | |
kubectl --namespace miles-spin-dev apply -f manifest.yaml |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:latest | |
RUN apt-get update && apt-get -y upgrade && apt-get install sudo | |
RUN useradd -ms /bin/bash mmatthias && mkdir -p /home/mmatthias/.ssh && \ | |
echo "mmatthias ALL=(ALL) NOPASSWD:ALL" | tee -a /etc/sudoers | |
RUN apt-get install -y git curl netcat redis-server \ | |
openjdk-8-jdk python python3.7 vim | |
USER mmatthias | |
RUN curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash | |
# Do this when I first login, although I wish I could get this to work in Docker build. | |
#RUN /bin/bash -c source "/home/mmatthias/.bashrc" && nvm install v10.15.3 && npm install -g yarn | |
#FIXME | |
COPY ssh-key* /home/mmatthias/.ssh/ | |
COPY local-git-setup.sh /home/mmatthias/ | |
ENV GCLOUD_VERSION=233.0.0 | |
RUN cd /home/mmatthias && \ | |
curl -L0 --silent -o google-cloud-sdk-${GCLOUD_VERSION}-linux-x86_64.tar.gz \ | |
https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-sdk-${GCLOUD_VERSION}-linux-x86_64.tar.gz && \ | |
tar xf google-cloud-sdk-${GCLOUD_VERSION}-linux-x86_64.tar.gz && \ | |
rm google-cloud-sdk-${GCLOUD_VERSION}-linux-x86_64.tar.gz | |
RUN /home/mmatthias/google-cloud-sdk/bin/gcloud components install alpha --quiet | |
RUN echo "PATH=$PATH:/home/mmatthias/google-cloud-sdk/bin" >> /home/mmatthias/.bashrc | |
WORKDIR /home/mmatthias | |
CMD tail -f /var/log/lastlog |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment