π¨π»βπ» Personal profile+blog created using Gatsby, React & GraphQL.
MIT License
This is my personal profile/blog where I write down my thought and notes about the interesting stuff I'm learning about the web everyday!
[!IMPORTANT] This website is using an older build of GatsbyJS, so in order to run this project successfully, you'll need Node v14.21.3
Clone the repo
git clone https://github.com/sydrawat/sydrawat.git
Install dependencies
Navigate into the siteβs directory and install the dependencies.
yarn install
Start developing.
cd sydrawat/
yarn develop
View your site!
The site is now running at http://localhost:8000
!
Note: You'll also see a second link:http://localhost:8000/___graphql
. This is the GraphiQL tool you can use to experiment with querying your data. Learn more about using this tool in the Gatsby tutorial.
NOTE : For deployment, follow the Gatsby AWS S3 guide for more detailed steps on how to deploy the site on AWS. If you're looking for different resources to deploy/host your site, have a look here.
The containerized image of this personal website is available on hub.docker.com/r/sydrawat/sydrawat.dev. In order to use this locally, or to deploy this on a Kubernetes cluster, make sure you use the appropriate image and tag names.
Local Development with Docker
docker pull sydrawat/sydrawat.dev:<tag>
# docker pull sydrawat/sydrawat.dev:latest
Run the container locally
# The -p option exposes the application running on port 8000 on the container
# to port 8000 on the host machine running the container
docker run -p 8000:8000 sydrawat/sydrawat.dev
The application should now be accessible on http://localhost:8000
Deployment on Kubernetes
Deployment on Kubernetes can vary, depending on how you want your application to be available. This is a simple example on how to run the website, which is containerized, as a Pod on a Kubernetes cluster.
kubectl run sydrawat --image=sydrawat/sydrawat.dev:latest
Next, we need to expose the application on a NodePort
:
apiVersion: v1
kind: Service
metadata:
labels:
app: sydrawat-svc
name: sydrawat-svc
namespace: default
spec:
ports:
- name: 8000-8000
nodePort: 31136
port: 8000
protocol: TCP
targetPort: 8000
selector:
run: sydrawat
type: NodePort
You can now test the application running on http://:31136 To identify what node your Pod is running on, use:
kubectl get pods -o wide # identify the node on which this pod is running
kubectl get nodes -o wide # get the node-ip
This project is open source and available under the MIT License.
Before you create an issue, please go through the Code of Conduct and follow the structure of template provided for raising an issue.
Thanks for reporting the problem!