Skip to content

Instantly share code, notes, and snippets.

View jack2jm's full-sized avatar

Jatin Mandanka jack2jm

View GitHub Profile
********** Add A Record ***********
1.An A record with @ pointing to your server’s public IP address.
2. An A record with www pointing to your server’s public IP address.
************* check if apache installed or not *****
sudo apache2ctl configtest -> it will return not found commmand
install
sudo apt update
sudo apt install apache2
sudo ufw app list //check firewall list
Master Link - https://developers.google.com/search/apis/indexing-api/v3/prereqs
---------------------------
Step: 1
1. Create project first. Give Name like Domain. (eg. example.com)
2. Enable Indexing API (https://console.developers.google.com/start/api?id=indexing.googleapis.com&credential=client_key)
(They are asking for - Data (select *appilcation data*))
2. Open the Service accounts page. If prompted, select a project. (https://console.developers.google.com/iam-admin/serviceaccounts)
@jack2jm
jack2jm / Fix PHP Multiple Version - How to Switch or move back to Installed PHP Version
Last active February 12, 2024 05:50
This will help you to change any running php version into ubuntu.
1. Call this command
updatedb
2. Locate php bin file
locate bin/php
3. check directories
ls -l /usr/bin/php
4. Remove current php linking into bin dirctory
rm /usr/bin/php
5. Create link for php version you want to use it (here is need to back to 7.4 - it must be installed)
ln -s /usr/bin/php7.4 /usr/bin/php
0. Import this to controller
use Intervention\Image\ImageManagerStatic as Image;
use Storage;
use File;
1. Use this function to convert to specific ratio
// path like /var/www/html/testproject/storage/app/public/item_images/64c100497075c4c6c1075b89
// filename - jatin.png
// $width, $height - pass to required size
// $maintain_ratio - same image size is require or not - other wise it will give $height * $image
1. create repo to bitbucket.
2. Enable pipeline from repo settings.
3. create 2 files to current repo. (bitbucket-pipelines.yml and execute.sh)
4. Now commit any push to local pc and you can navigate to pipeline page to repo.
Create repo pipeline environment variables to repository settings.
******************************************************************
1. DEPLOY_USER_J -> write server username for login
root
Here are basic steps to integrate Bitbucket pipeline - where project is already setuped to server.
*********Here is test to yml validtor - https://bitbucket-pipelines.atlassian.io/validator
Create varibles into bitbucket repo settings
*************************************************
REPO_ORIGIN_URL -> url to git pull with username and password
https://username:token@bitbucket.org/workspace/projectreponame.git
DEPLOY_USER_J -> server username
@Bhavya8181
Bhavya8181 / Setup Laravel Project in windows server
Last active February 1, 2024 08:05
setup & install require packege for setup laravel project in windows server iis
Ref Link
======================
- https://www.youtube.com/watch?v=YMMFfAad3y8
-
1. Base on laravel project version you should ensure that your web server has the following minimum PHP version and extensions: it will find from official website
https://laravel.com/docs/9.x/deployment#server-requirements (select your version and find server requirement on laravel.com official website)
2. Using Remote desktop connection login with your server credentials
@jack2jm
jack2jm / Setup Laravel Project in windows server
Last active May 27, 2024 06:55 — forked from Bhavya8181/Setup Laravel Project in windows server
setup & install require packege for setup laravel project in windows server iis
Ref Link
======================
Free SSL windows
https://gist.github.com/jack2jm/0aebaea31f467581e0bc7b599a485a0a
youtube video
https://www.youtube.com/watch?v=YMMFfAad3y8
https://www.youtube.com/watch?v=1p985k-sGoc
Enable IIS windows
https://help.claris.com/en/server-installation-configuration-guide/content/enabling-iis-windows.html
Add CGI module

Important Gists


Laravel

1.JWT Auth Laravel10 - email/phone
    https://gist.github.com/jack2jm/21b13f96ceec49694967477ecae61334
2.Laravel setup into windows server
Full Doc to learn react
--------------------------------
https://docs.google.com/document/d/1xlMUk6OMMF42X3w1ZG94BnKcmbGI7f5FoF1kCyCBC9Q/edit?usp=sharing
Installations + SSL React
https://medium.com/@poudel.01anuj/deploying-reactjs-project-on-the-linux-server-with-ssl-certificate-https-aa14bf2737aa
--------------------------------
In react js you can store&use enviorment variable
- Create .env file in root of project