Skip to content

Instantly share code, notes, and snippets.

FROM python:3.5-alpine
COPY . /app
WORKDIR /app
CMD python ./main.py
import time
print("Hello World Printed every minute!!!")
apiVersion: v1
kind: Service
metadata:
name: hello-python-service
spec:
selector:
app: hello-python
ports:
- protocol: "TCP"
port: 6000
apiVersion: v1
kind: Service
metadata:
name: hello-python-service
spec:
selector:
app: hello-python
ports:
- protocol: "TCP"
port: 6000
FROM python:3-alpine
RUN mkdir /app
WORKDIR /app
COPY main.py /app
RUN pip install flask
EXPOSE 5000
CMD ["python", "main.py"]
import time
from flask import Flask
app = Flask(__name__)
@app.route("/")
def hello():
return "Hello"
@app.route('/hellovamsi')
def hellovamsi():
import time
from flask import Flask
app = Flask(__name__)
@app.route("/")
def hello():
return "Hello"
@app.route('/hellovamsi')
def hellovamsi():
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: fluent-bit
labels:
app: fluent-bit
spec:
selector:
matchLabels:
app: fluent-bit
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: fluent-bit
labels:
app: fluent-bit
spec:
selector:
matchLabels:
app: fluent-bit
apiVersion: serving.knative.dev/v1alpha1
kind: Service
metadata:
name: hellowhale-knative
namespace: default
spec:
template:
spec:
containers:
- image: docker.io/vamsijakkula/hellowhale-knative