Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sumanthratna/website
My fast and beautiful personal website.
https://github.com/sumanthratna/website
bootstrap4 cms php smarty
Last synced: 22 days ago
JSON representation
My fast and beautiful personal website.
- Host: GitHub
- URL: https://github.com/sumanthratna/website
- Owner: sumanthratna
- License: mit
- Created: 2019-07-20T19:54:14.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-01-16T10:03:27.000Z (almost 2 years ago)
- Last Synced: 2024-10-30T14:09:25.377Z (2 months ago)
- Topics: bootstrap4, cms, php, smarty
- Language: Smarty
- Homepage:
- Size: 5.44 MB
- Stars: 2
- Watchers: 1
- Forks: 1
- Open Issues: 45
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# @sumanthratna's Website
[![Code Quality Score](https://www.code-inspector.com/project/7968/score/svg)](https://frontend.code-inspector.com/public/project/7968/website/dashboard)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/af03513b3ff944a0b1bba6ed91303724)](https://www.codacy.com?utm_source=github.com&utm_medium=referral&utm_content=sumanthratna/website&utm_campaign=Badge_Grade)## Setting up the files
.
├── private
│ ├── keys.ini
│ ├── php.error.log
│ └── smarty
│ ├── cache
│ │ └── ...
│ ├── configs
│ │ └──
│ └── templates_c
│ └── ...
└── public
└──Note: the `public` is this repository itself—it doesn't exactly contain this repository. Here's a script to set everything up (run this in an empty folder):
```sh
mkdir private
touch private/keys.ini
git clone [email protected]:sumanthratna/website.git public
cd public
composer install
./compile all
```## Creating `keys.ini`
Here's what `keys.ini` should look like:
```ini
neverbounce_key=
sendgrid_key=
secret=[recaptcha]
secret=
site_key=[database]
name='site_2022sratna'
host='mysql1.csl.tjhsst.edu'
port='3306'
username=
password=
```## Preparing the MySQL Database
Note: there must be at least one user with the username `"admin"` in order for the admin panel to work.
```sql
-- Create the table:
CREATE TABLE users(id INT NOT NULL AUTO_INCREMENT, username VARCHAR(255) NOT NULL, password VARCHAR(255) NOT NULL, PRIMARY KEY(id))-- Create a login account:
INSERT INTO users(username, password) VALUES("admin", SHA2("MySecurePassword!", 512))-- Show login info (username and SHA-512 of password) of a certain user:
SELECT username,password FROM users WHERE username="admin"-- Show login info (username and SHA-512 of password) of all login accounts:
SELECT * FROM users-- Remove a certain user's login account:
DELETE FROM users WHERE username="admin"-- Remove the table:
DROP TABLE users
```## Configuring Nginx
On Director, this should be the only change made:
```nginx
server {
...
location / {
...
try_files $uri $uri/ /index.php?$args;
}
...
}
```This allows routing from [`index.php`](./index.php).