Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ exclude: |

repos:
# auto formatters (no work required) #############################################################
# - repo: https://github.com/pre-commit/pre-commit-hooks
# rev: v5.0.0
# hooks:
# - id: trailing-whitespace
# - id: end-of-file-fixer
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- repo: local
hooks:
- id: phpcbf
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
![UNITY](https://user-images.githubusercontent.com/40907639/137608695-2d914da2-1ecc-480b-a47e-a9e33b2b1b45.png)

# Unity Web Portal
Unity Web Portal is a PHP application built in top of MariaDB and LDAP which acts as a central user portal for high-performance-computing clusters.
Unity Web Portal is a PHP application built in top of MariaDB and LDAP which acts as a central user portal for high-performance-computing clusters.

Basic Features:
* User signs up
Expand Down Expand Up @@ -113,7 +113,7 @@ rm "$prod" && ln -s "$old" "$prod"
ADD `firstname` VARCHAR(768) NOT NULL AFTER `timestamp`,
ADD `lastname` VARCHAR(768) NOT NULL AFTER `firstname`,
ADD `email` VARCHAR(768) NOT NULL AFTER `lastname`,
ADD `org` VARCHAR(768) NOT NULL AFTER `email`;
ADD `org` VARCHAR(768) NOT NULL AFTER `email`;
```

### 1.1 -> 1.2
Expand Down
2 changes: 1 addition & 1 deletion deployment/config/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

In this folder only one file can be created at this time: `config.ini`.

In this file you can override any of the config from the default file in `defaults/config.ini.default`. **Every deployment needs this**
In this file you can override any of the config from the default file in `defaults/config.ini.default`. **Every deployment needs this**
2 changes: 1 addition & 1 deletion deployment/custom_user_mappings/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ Put any csv in this folder in the format:

<netid>,<user id>

and the website will auto assign that id (assuming it is available) when that user applies for an account.
and the website will auto assign that id (assuming it is available) when that user applies for an account.
2 changes: 1 addition & 1 deletion deployment/mail_overrides/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Mail Overrides

In this location, you can copy any file in the resources/mail folder into here and modify it. **The filename must remain the same**
In this location, you can copy any file in the resources/mail folder into here and modify it. **The filename must remain the same**
2 changes: 1 addition & 1 deletion deployment/overrides/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ For example, if the primary virtual host is `example.com`, but you wanted to hos
config.ini
```

Everything else in the deployment folder cannot be overridden.
Everything else in the deployment folder cannot be overridden.
2 changes: 1 addition & 1 deletion resources/mail/account_deletion_request_admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@
<strong>Name</strong> <?php echo $data["name"]; ?>
<br>
<strong>Email</strong> <?php echo $data["email"]; ?>
</p>
</p>
6 changes: 3 additions & 3 deletions resources/mail/footer.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<footer style="text-align: center; font-size: 8pt; color: #aaaaaa; border-top: 1px solid #dddddd; padding-top: 10px;">
<span>You are receiving this email because you have an account
on the <a target='_blank' href='<?php echo $this->MSG_LINKREF; ?>'>Unity Cluster</a>.
If you would like to stop receiving these emails,
<span>You are receiving this email because you have an account
on the <a target='_blank' href='<?php echo $this->MSG_LINKREF; ?>'>Unity Cluster</a>.
If you would like to stop receiving these emails,
you may request to close your account by replying to this email.</span>
</footer>
4 changes: 2 additions & 2 deletions resources/mail/group_created.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<p>Hello,</p>

<p>Your request for a PI account on the Unity cluster has been approved. You can access the management
<p>Your request for a PI account on the Unity cluster has been approved. You can access the management
page for your group <a href="<?php echo $this->MSG_LINKREF; ?>/panel/pi.php">on this page</a>.</p>

<p>Do not hesitate to reply if you have any questions!</p>
<p>Do not hesitate to reply if you have any questions!</p>
4 changes: 2 additions & 2 deletions resources/mail/group_denied.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@

<p>Hello,</p>

<p>Unfortunately, your request for a PI account on the Unity cluster has not been approved.
<p>Unfortunately, your request for a PI account on the Unity cluster has not been approved.
Usually, this is due to one of the following reasons:</p>

<ul>
<li>You are not a PI at your organization</li>
<li>We were not able to verify your PI status. In this case please reply with verification</li>
<li>Your organization has not been authorized on the Unity Cluster.
<li>Your organization has not been authorized on the Unity Cluster.
In this case please reply with more information about your request</li>
</ul>

Expand Down
4 changes: 2 additions & 2 deletions resources/mail/group_disband.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<p>Hello,</p>

<p>Your PI group, <?php echo $data["group_name"] ?>, has been disbanded on the Unity
<p>Your PI group, <?php echo $data["group_name"] ?>, has been disbanded on the Unity
cluster. Any jobs associated with this PI account have been killed.</p>

<p>If you believe this to be a mistake, please reply to this email</p>
<p>If you believe this to be a mistake, please reply to this email</p>
4 changes: 2 additions & 2 deletions resources/mail/group_request.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<p>Hello,</p>

<p>You have requested a PI account on the Unity Cluster.
<p>You have requested a PI account on the Unity Cluster.
The admin team is reviewing this request, and you will receive an email soon with more details.</p>

<p>Do not hesitate to reply if you have any questions!</p>
<p>Do not hesitate to reply if you have any questions!</p>
2 changes: 1 addition & 1 deletion resources/mail/group_request_admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@
<strong>Email</strong> <?php echo $data["email"]; ?>
</p>

<p>You can approve this account <a href="<?php echo $this->MSG_LINKREF; ?>/admin/pi-mgmt.php">here</a>.</p>
<p>You can approve this account <a href="<?php echo $this->MSG_LINKREF; ?>/admin/pi-mgmt.php">here</a>.</p>
6 changes: 3 additions & 3 deletions resources/mail/group_user_added.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@

<p>Hello,</p>

<p>You have been approved to join the PI group <?php echo $data["group"]; ?>.
Navigate to the <a href="<?php echo $this->MSG_LINKREF; ?>/panel/groups.php">my groups</a>
<p>You have been approved to join the PI group <?php echo $data["group"]; ?>.
Navigate to the <a href="<?php echo $this->MSG_LINKREF; ?>/panel/groups.php">my groups</a>
page to see your PI groups.</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
2 changes: 1 addition & 1 deletion resources/mail/group_user_added_owner.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@
<strong>Email</strong> <?php echo $data["email"]; ?>
</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
2 changes: 1 addition & 1 deletion resources/mail/group_user_denied.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@

<p>You have been denied from joining the PI group <?php echo $data["group"]; ?>.</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
4 changes: 2 additions & 2 deletions resources/mail/group_user_denied_owner.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<p>Hello,</p>

<p>A user has been denied from joining your PI group, <?php echo $data["group"]; ?>.
<p>A user has been denied from joining your PI group, <?php echo $data["group"]; ?>.
The details of the denied user are below:</p>

<p>
Expand All @@ -19,4 +19,4 @@
<strong>Email</strong> <?php echo $data["email"]; ?>
</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
2 changes: 1 addition & 1 deletion resources/mail/group_user_removed.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@

<p>You have been removed from the PI group <?php echo $data["group"]; ?>.</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
2 changes: 1 addition & 1 deletion resources/mail/group_user_removed_owner.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@
<strong>Email</strong> <?php echo $data["email"]; ?>
</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
2 changes: 1 addition & 1 deletion resources/mail/group_user_request.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@

<p>You have requested to join the group <?php echo $data["group"]; ?>.</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
4 changes: 2 additions & 2 deletions resources/mail/group_user_request_owner.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,5 @@
<strong>Email</strong> <?php echo $data["email"]; ?>
</p>

<p>You can approve or deny this user on the
<a href="<?php echo $this->MSG_LINKREF; ?>/panel/pi.php">my users</a> page</p>
<p>You can approve or deny this user on the
<a href="<?php echo $this->MSG_LINKREF; ?>/panel/pi.php">my users</a> page</p>
6 changes: 3 additions & 3 deletions resources/mail/user_created.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
<strong>Organization</strong> <?php echo $data["org"]; ?>
</p>

<p>Please login to the web portal to access Unity.
If you need console access, you will need to set your SSH keys in the
<p>Please login to the web portal to access Unity.
If you need console access, you will need to set your SSH keys in the
<a href="<?php echo $this->MSG_LINKREF; ?>/panel/account.php">account settings</a> page.</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
6 changes: 3 additions & 3 deletions resources/mail/user_loginshell.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@

<p>Hello,</p>

<p>You have updated your login shell on the Unity cluster to <?php echo $data["new_shell"]; ?>.
You can view the login shell settings on the
<p>You have updated your login shell on the Unity cluster to <?php echo $data["new_shell"]; ?>.
You can view the login shell settings on the
<a href="<?php echo $this->MSG_LINKREF; ?>/panel/account.php">account settings</a> page</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
4 changes: 2 additions & 2 deletions resources/mail/user_sshkey.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
}
?>

<p>You can view the SSH public keys attached to your account on
<p>You can view the SSH public keys attached to your account on
the <a href="<?php echo $this->MSG_LINKREF; ?>/panel/account.php">account settings</a> page.</p>

<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
<p>If you believe this to be a mistake, please reply to this email as soon as possible.</p>
2 changes: 1 addition & 1 deletion resources/templates/footer.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
for ($i = 0; $i < count($footer_logos); $i++) {
echo
"<a target='_blank' href='" . $footer_links[$i] . "'>
<img src='" . $CONFIG["site"]["prefix"] . "/assets/" . $footer_logos[$i] . "'
<img src='" . $CONFIG["site"]["prefix"] . "/assets/" . $footer_logos[$i] . "'
draggable='false' title='" . $footer_titles[$i] . "'></a>";
}
?>
Expand Down
2 changes: 1 addition & 1 deletion resources/templates/header.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
<body>

<header>
<img id="imgLogo" draggable=false
<img id="imgLogo" draggable=false
src="<?php echo $CONFIG["site"]["prefix"]; ?>/assets/<?php echo $CONFIG["site"]["logo"]; ?>">
<button class="hamburger vertical-align">
<img draggable="false" src="<?php echo $CONFIG["site"]["prefix"]; ?>/assets/menu.png" alt="Menu Button">
Expand Down
2 changes: 1 addition & 1 deletion tools/docker-dev/identity/ldap-config.ldif
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ add: olcAccess
olcAccess: {1}to * by * read
-
add: olcSizeLimit
olcSizeLimit: unlimited
olcSizeLimit: unlimited
2 changes: 1 addition & 1 deletion tools/docker-dev/identity/phpldapadmin-apache.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
ServerName identity
DocumentRoot /usr/share/phpldapadmin/htdocs

</VirtualHost>
</VirtualHost>
2 changes: 1 addition & 1 deletion tools/docker-dev/identity/ssh.ldif
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ olcAttributeTypes: ( 1.3.6.1.4.1.24552.500.1.1.1.13 NAME 'sshPublicKey'
olcObjectClasses: ( 1.3.6.1.4.1.24552.500.1.1.2.0 NAME 'ldapPublicKey' SUP top AUXILIARY
DESC 'MANDATORY: OpenSSH LPK objectclass'
MAY ( sshPublicKey $ uid )
)
)
2 changes: 1 addition & 1 deletion tools/docker-dev/sql/phpmyadmin-apache.conf
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@
Require all denied
</Directory>

</VirtualHost>
</VirtualHost>
2 changes: 1 addition & 1 deletion tools/docker-dev/web/unity-apache.conf
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,4 @@
SetEnv mail "DevName@DevDomain.com"
</Location>

</VirtualHost>
</VirtualHost>
2 changes: 1 addition & 1 deletion webroot/css/filters.css
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@

.key td:hover {
cursor: pointer;
}
}
2 changes: 1 addition & 1 deletion webroot/css/modal.css
Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,4 @@ div.modalBody>* {
.buttonList>* {
display: inline-block;
margin-right: 10px;
}
}
2 changes: 1 addition & 1 deletion webroot/js/filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,4 +87,4 @@ function filterRows() {
}
);
}
}
}
4 changes: 2 additions & 2 deletions webroot/js/sort.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,12 +62,12 @@ window.onload = function() {
var sortElement = document.getElementById(sort);
if (sortElement) {
if (order == "asc") {
sortElement.click();
sortElement.click();
} else if (order == "desc") {
sortElement.click();
sortElement.click();
}
}
}
filterRows();
}
}