Skip to content

Commit

Permalink
Merge pull request #473 from petio-team/dev
Browse files Browse the repository at this point in the history
Release 0.5.2
  • Loading branch information
AshDyson authored Jul 8, 2021
2 parents 0aeef82 + 7043b0c commit 7e2b583
Show file tree
Hide file tree
Showing 46 changed files with 1,017 additions and 514 deletions.
12 changes: 6 additions & 6 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,31 +2,31 @@ version: 2
updates:
- package-ecosystem: "npm"
directory: "/"
target-branch: "develop"
target-branch: "dev"
schedule:
interval: "daily"
- package-ecosystem: "npm"
directory: "/admin"
target-branch: "develop"
target-branch: "dev"
schedule:
interval: "daily"
- package-ecosystem: "npm"
directory: "/api"
target-branch: "develop"
target-branch: "dev"
schedule:
interval: "daily"
- package-ecosystem: "npm"
directory: "/frontend"
target-branch: "develop"
target-branch: "dev"
schedule:
interval: "daily"
- package-ecosystem: "docker"
directory: "/"
target-branch: "develop"
target-branch: "dev"
schedule:
interval: "daily"
- package-ecosystem: "docker"
directory: "/api"
target-branch: "develop"
target-branch: "dev"
schedule:
interval: "daily"
49 changes: 28 additions & 21 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,28 +1,34 @@
FROM --platform=linux/amd64 node:14.15.1-alpine3.12 as builder
FROM node:16.3.0-alpine3.13 as builder

RUN apk add --no-cache git
COPY ./ /source/
RUN mkdir /build && \
cp /source/petio.js /build/ && \
cp /source/router.js /build/ && \
cp /source/package.json /build/ && \
cd /build && \
npm install && \
cp -R /source/frontend /build/ && \
cp -R /source/admin /build/ && \
cp -R /source/api /build/ && \
cd /build/frontend && \
npm install && npm run build && \
cd /build/admin && \
npm install && npm run build && \
cd /build/api && \

WORKDIR /build
RUN cp /source/petio.js . && \
cp /source/router.js . && \
cp /source/package.json . && \
npm install && \
cd /build && \
mkdir /build/views && \
mv /build/frontend/build /build/views/frontend && rm -rf /build/frontend && \
mv /build/admin/build /build/views/admin && rm -rf /build/admin && \
chmod -R u=rwX,go=rX /build
cp -R /source/frontend . && \
cp -R /source/admin . && \
cp -R /source/api .

WORKDIR /build/frontend
RUN npm install && \
npm run build

WORKDIR /build/admin
RUN npm install --legacy-peer-deps && \
npm run build

WORKDIR /build/api
RUN npm install --legacy-peer-deps

WORKDIR /build/views
RUN mv /build/frontend/build /build/views/frontend && \
rm -rf /build/frontend && \
mv /build/admin/build /build/views/admin && \
rm -rf /build/admin && \
chmod -R u=rwX,go=rX /build

FROM alpine:3.13

Expand All @@ -38,6 +44,7 @@ COPY --from=builder /build/ /app/

LABEL org.opencontainers.image.vendor="petio-team"
LABEL org.opencontainers.image.url="https://github.com/petio-team/petio"
LABEL org.opencontainers.image.documentation="https://github.com/petio-team/petio-docs/wiki"
LABEL org.opencontainers.image.documentation="https://docs.petio.tv/"
LABEL org.opencontainers.image.licenses="MIT"

HEALTHCHECK --interval=30s --timeout=30s --start-period=5s --retries=3 CMD [ "wget", "--spider", "http://localhost:7777/health" ]
1 change: 1 addition & 0 deletions LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,4 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,23 +20,23 @@ Allow your users to interact with media both on and off your server with this ap
<h4>1. Installation</h4>
This application can be installed to run in docker or as a standalone binary that can be configured to run as a service. See our docs below for guides on different setup methods.
<ul><li>
<p><a target="_blank" href="https://github.com/petio-team/petio-docs/wiki/Docker">Docker installation</a></p>
<p><a target="_blank" href="https://docs.petio.tv/install-guides/docker">Docker installation</a></p>
</li></ul>

Binary (executable file) guides
**note:** this method requires a local mongodb instance to be installed
<ul>
<li><a target="_blank" href="https://github.com/petio-team/petio-docs/wiki/Windows">Windows</a> </li>
<li><a target="_blank" href="https://github.com/petio-team/petio-docs/wiki/Linux">Linux</a> </li>
<li><a target="_blank" href="https://github.com/petio-team/petio-docs/wiki/MacOS">MacOS</a></li>
<li><a target="_blank" href="hhttps://docs.petio.tv/install-guides/windows">Windows</a> </li>
<li><a target="_blank" href="https://docs.petio.tv/install-guides/linux">Linux</a> </li>
<li><a target="_blank" href="https://docs.petio.tv/install-guides/macos">MacOS</a></li>
</ul>

<h4>2. Configuring Petio</h4>
Configuring Petio is fairly straight forward but our docs cover the process, from initial server conenction to email / Sonarr / Radarr.
<p><a target="_blank" href="https://github.com/petio-team/petio-docs/wiki/Configuration">How to configure Petio</a></p>
<p><a target="_blank" href="https://docs.petio.tv/configuration/first-time-setup">How to configure Petio</a></p>

<h2>Frequently Asked Questions</h2>
<p>Our FAQs can be found <a href="https://github.com/petio-team/petio-docs/wiki/FAQ">here</a></p>
<p>Our FAQs can be found <a href="https://docs.petio.tv/troubleshooting/troubleshooting-faq">here</a></p>

<h2>Credits</h2>
<h4>Attribution Credits</h4>
Expand Down
34 changes: 17 additions & 17 deletions admin/package.json
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
{
"name": "petio-admin",
"version": "0.5.1-alpha",
"version": "0.5.2-alpha",
"private": true,
"homepage": ".",
"dependencies": {
"@testing-library/jest-dom": "^5.11.9",
"@testing-library/react": "^11.2.5",
"@testing-library/user-event": "^12.7.2",
"node-sass": "^5.0.0",
"react": "^17.0.1",
"@testing-library/jest-dom": "^5.14.1",
"@testing-library/react": "^11.2.7",
"@testing-library/user-event": "^12.8.3",
"react": "^17.0.2",
"react-charts": "^2.0.0-beta.7",
"react-dom": "^16.13.1",
"react-dom": "^17.0.2",
"react-lazy-load-image-component": "^1.5.1",
"react-redux": "^7.2.2",
"react-redux": "^7.2.4",
"react-router": "^5.1.2",
"react-router-dom": "^5.2.0",
"react-scripts": "4.0.2",
"recharts": "^2.0.8",
"redux": "^4.0.5",
"redux-devtools-extension": "^2.13.8",
"recharts": "^2.0.9",
"redux": "^4.1.0",
"redux-devtools-extension": "^2.13.9",
"redux-thunk": "^2.3.0",
"sass": "1.34.1",
"uuid": "^8.3.2",
"web-vitals": "^1.1.0"
"web-vitals": "^2.0.1"
},
"scripts": {
"start": "react-scripts start",
Expand All @@ -44,10 +44,10 @@
]
},
"devDependencies": {
"eslint": "^7.20.0",
"eslint-config-prettier": "^7.2.0",
"eslint-plugin-prettier": "^3.3.1",
"eslint-plugin-react": "^7.22.0",
"prettier": "^2.2.1"
"eslint": "^7.29.0",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-prettier": "^3.4.0",
"eslint-plugin-react": "^7.24.0",
"prettier": "^2.3.1"
}
}
1 change: 1 addition & 0 deletions admin/src/assets/svg/notifications.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
29 changes: 27 additions & 2 deletions admin/src/components/FilterRow.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,33 @@ class FilterRow extends React.Component {
language: {
type: "string",
value: "language",
label: "Language"
}
label: "Language",
},
popularity: {
type: "number",
value: "popularity",
label: "Popularity",
},
network: {
type: "string",
value: "network",
label: "Network",
},
studio: {
type: "string",
value: "studio",
label: "Studio",
},
adult: {
type: "string",
value: "adult",
label: "Adult",
},
status: {
type: "string",
value: "status",
label: "Status",
},
};
const operators = {
equals: {
Expand Down
20 changes: 18 additions & 2 deletions admin/src/components/RequestsTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,15 @@ class RequestsTable extends React.Component {
<Arrow />
</th>
<th>Year</th>
<th>Type</th>
<th
className={`sortable ${
this.state.sortBy === "type" ? "active" : ""
} ${this.state.dir}`}
onClick={() => this.sortCol("type")}
>
Type
<Arrow />
</th>
<th
className={`sortable ${
this.state.sortBy === "status" ? "active" : ""
Expand All @@ -267,7 +275,15 @@ class RequestsTable extends React.Component {
<Arrow />
</th>
<th>Users</th>
<th>Approved</th>
<th
className={`fixed sortable ${
this.state.sortBy === "approved" ? "active" : ""
} ${this.state.dir}`}
onClick={() => this.sortCol("approved")}
>
Approved
<Arrow />
</th>
<th>Actions</th>
</tr>
</thead>
Expand Down
1 change: 1 addition & 0 deletions admin/src/page/Requests.js
Original file line number Diff line number Diff line change
Expand Up @@ -597,6 +597,7 @@ class Requests extends React.Component {
<option value="">None</option>
<option value="3">Processing</option>
<option value="4">Finalising</option>
<option value="5">Complete</option>
</select>
</div>
</>
Expand Down
23 changes: 20 additions & 3 deletions admin/src/page/Settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@ import { withRouter, Link, Switch, Route } from "react-router-dom";
import { ReactComponent as GeneralIcon } from "../assets/svg/settings-general.svg";
import { ReactComponent as ConsoleIcon } from "../assets/svg/console.svg";
import { ReactComponent as FilterIcon } from "../assets/svg/filter.svg";
import { ReactComponent as NotificationsIcon } from "../assets/svg/notifications.svg";
import Console from "./settings/console";
import General from "./settings/general";
import Radarr from "./settings/radarr";
import Sonarr from "./settings/sonarr";
import Filter from "./settings/filter";
import Notifications from "./settings/notifications";

class Settings extends React.Component {
constructor(props) {
Expand Down Expand Up @@ -86,6 +88,18 @@ class Settings extends React.Component {
<FilterIcon />
</div>
</Link>
<Link
to="/settings/notifications"
className={
"settings--menu--item " +
(current === "/settings/notifications" ? "active" : "")
}
>
<p>Notifications</p>
<div className="icon">
<NotificationsIcon />
</div>
</Link>
<Link
to="/settings/console"
className={
Expand All @@ -110,12 +124,15 @@ class Settings extends React.Component {
<Route path="/settings/sonarr">
<Sonarr msg={this.props.msg} />
</Route>
<Route path="/settings/console">
<Console msg={this.props.msg} />
</Route>
<Route path="/settings/filter">
<Filter msg={this.props.msg} />
</Route>
<Route path="/settings/notifications">
<Notifications msg={this.props.msg} />
</Route>
<Route path="/settings/console">
<Console msg={this.props.msg} />
</Route>
<Route path="*" exact>
<section>
<h1 className="main-title mb--1">Not found</h1>
Expand Down
Loading

0 comments on commit 7e2b583

Please sign in to comment.