Skip to content
Snippets Groups Projects
Commit a1aa82c7 authored by Imre Toth's avatar Imre Toth
Browse files

ICSHWI-9486: Finalizing phrases

parent b0665943
No related branches found
No related tags found
4 merge requests!270Merging develop branch to master in order to create RC,!222Fixing missing time interval parameter for logs,!202Merging develop to master,!187ICSHWI-9486: Finalizing phrases
REACT_APP_SERVER_ADDRESS=https://localhost/api
REACT_APP_API_BASE_ENDPOINT=/ccce-api
REACT_APP_API_BASE_ENDPOINT=/api/spec
REACT_APP_TOKEN_RENEW_INTERVAL=180000
\ No newline at end of file
<script>
window.SERVER_ADDRESS=''
window.API_BASE_ENDPOINT='/ccce-api'
window.API_BASE_ENDPOINT='/api/spec'
window.TOKEN_RENEW_INTERVAL=180000
window.CCDB_ADDRESS='https://ccdb.esss.lu.se'
window.ENVIRONMENT_TITLE = ''
......
# build CCCE Frontend
# build CE deployment Frontend
FROM node:16.14.0 as builder
RUN mkdir /usr/src/app
WORKDIR /usr/src/app
......
# CCCE deployment tool web UI
# CE deployment tool web UI
This project is meant to be the web User Interface for the CCCE Deployment tool. The project is written in ReactJS.
This project is meant to be the web User Interface for the CE Deployment tool. The project is written in ReactJS.
## Developing environment
* NodeJS and npm
......@@ -36,7 +36,8 @@ The following values can be set in the file:
| Environment variable | Description |
| -------------------------|-------------|
| SERVER_ADDRESS | The backend server base URL _(host:port)_ (if backend server is running natively on the same host as the UI then the value has to be empty, and proxy has to be set!)|
| API_BASE_ENDPOINT | The context path of the application's REST API _(e.g. /ccce-api)_ |
| API_BASE_ENDPOINT | The context path of the application's REST API _(e.g. /api/spec)_ |
| SWAGGER_UI_URL | The URL for the backend Swagger-ui interface _(e.g./api/docs)_ |
| TOKEN_RENEW_INTERVAL | Time interval to renew JWT auth token _(in milliseconds)_ |
| CCDB_ADDRESS | CCDB service base URL (used for IOC name CCDB reference feature) |
| ENVIRONMENT_TITLE | Adds a (sub)text to the HTLM title, and also for the appBar header. Supposed to show information to the user which environment they are using. The default value is empty. _Optional field!_ |
......
......@@ -23,4 +23,4 @@
//
// -- This will overwrite an existing command --
// Cypress.Commands.overwrite('visit', (originalFn, url, options) => { ... })
Cypress.Commands.add("login", () => {cy.setCookie("ccce-auth", "DEADBEEF")});
\ No newline at end of file
Cypress.Commands.add("login", () => {cy.setCookie("ce-deploy-auth", "DEADBEEF")});
\ No newline at end of file
......@@ -25,7 +25,7 @@ import { interceptAPI } from './interceptAPI'
// but copying is bad
// maybe we need to rethink how we do config
window.SERVER_ADDRESS=''
window.API_BASE_ENDPOINT='/ccce-api'
window.API_BASE_ENDPOINT='/api/spec'
window.TOKEN_RENEW_INTERVAL=180000
window.CCDB_ADDRESS='https://ccdb.esss.lu.se'
window.ENVIRONMENT_TITLE = ''
......
SERVER_ADDRESS=''
API_BASE_ENDPOINT='/ccce-api'
API_BASE_ENDPOINT='/api/spec'
SWAGGER_UI_URL='/api/docs'
TOKEN_RENEW_INTERVAL=180000
CCDB_ADDRESS='https://ccdb.esss.lu.se'
ENVIRONMENT_TITLE = ''
BACKEND_VERSION='1.0.0-rc9'
BACKEND_REPOSITORY_TAGS='https://gitlab.esss.lu.se/ccce/dev/ce-deploy-backend/-/tags/'
FRONTEND_VERSION='1.0.0-rc6'
FRONTEND_REPOSITORY_TAGS='https://gitlab.esss.lu.se/ccce/dev/ce-dploy-ui/-/tags/'
FRONTEND_REPOSITORY_TAGS='https://gitlab.esss.lu.se/ccce/dev/ce-deploy-ui/-/tags/'
......@@ -31,7 +31,7 @@ import { AppErrorBoundary } from "./components/navigation/ErrorBoundary/ErrorBou
//setting up the application (TAB)title
function App() {
useEffect(() => {
document.title = "CCCE" + applicationSubTitle();
document.title = "CE deployment" + applicationSubTitle();
}, []);
return (
......
......@@ -26,11 +26,11 @@ defineFeature(feature, (test) => {
});
when('the user navigates to the hosts page', async () => {
await screen.findByText('CCCE / IOC hosts');
await screen.findByText('CE deployment / IOC hosts');
});
then('they should be presented with a table of hosts from the iocs group in CSEntry', async () => {
expect(await screen.findByText('CCCE / IOC hosts')).toBeInTheDocument()
expect(await screen.findByText('CE deployment / IOC hosts')).toBeInTheDocument()
expect(await screen.findByText('Status')).toBeInTheDocument()
expect(await screen.findByText('Host')).toBeInTheDocument()
expect(await screen.findByText('Network')).toBeInTheDocument()
......
......@@ -16,7 +16,7 @@ function mountIntoHarness(children) {
}
function checkAPIDisplayed() {
cy.get('#api').contains('CCCE API');
cy.get('#api').contains('CE API');
}
function DisplayAPISpecification({api}) {
......
......@@ -31,7 +31,7 @@ describe("TokenRenew", () => {
mountIntoHarness(<TokenRenew />);
cy.tick(window.TOKEN_RENEW_INTERVAL);
cy.wait("@renew", {responseTimeout: 1000})
cy.getCookie('ccce-auth').should('have.property', 'value', 'FADEDEAD');
cy.getCookie('ce-deploy-auth').should('have.property', 'value', 'FADEDEAD');
})
})
})
\ No newline at end of file
......@@ -154,7 +154,7 @@ export function ButtonAppBar({ homeUrl, homeClick, title, button, profileButton,
);
}
const defaultTitle = "CCCE"
const defaultTitle = "CE deployment"
export const GlobalAppBarContext = createContext({
title: defaultTitle,
setButton: () => { console.log("default GlobalAppBarContext.setButton does nothing.") },
......@@ -457,7 +457,7 @@ export function useGlobalAppBar(initTitle, initButton) {
const appBar = useContext(GlobalAppBarContext);
useEffect(() => {
appBar.setButton(button);
appBar.setTitle('CCCE ' + applicationSubTitle() + ' / ' + title );
appBar.setTitle('CE deployment ' + applicationSubTitle() + ' / ' + title );
}, [appBar, title, button]);
return { setButton, setTitle };
}
\ No newline at end of file
{
"openapi": "3.0.1",
"info": {
"title": "CCCE API",
"description": "CCCE backend",
"title": "CE API",
"description": "CE backend",
"version": "0.0.5"
},
"servers": [
{
"url": "http://localhost:8080",
"description": "CCCE Deployment Backend"
"description": "CE Deployment Backend"
}
],
"tags": [
......
......@@ -23,17 +23,17 @@ function login(req) {
return {
body: { token },
headers: {
"Set-Cookie": `ccce-auth=${token}`
"Set-Cookie": `ce-deploy-auth=${token}`
}
}
}
function isLoggedIn(req) {
if (req.cookies) {
return Boolean(req.cookies["ccce-auth"]);
return Boolean(req.cookies["ce-deploy-auth"]);
}
else {
return (req.headers?.cookie ?? "").includes("ccce-auth=");
return (req.headers?.cookie ?? "").includes("ce-deploy-auth=");
}
}
......@@ -68,7 +68,7 @@ function renew(req) {
return {
body: { token },
headers: {
"Set-Cookie": `ccce-auth=${token}`
"Set-Cookie": `ce-deploy-auth=${token}`
}
}
}
......@@ -202,7 +202,7 @@ const qRegExp = (pattern) => RegExp(pattern + queryPattern)
// Handlers for our whole API
export const apiHandlers = [
// api spec
makeHandler("GET", qRegExp(".*/ccce-api"), mockAPI.spec),
makeHandler("GET", qRegExp(".*/api/spec"), mockAPI.spec),
// authentication
makeHandler("POST", qRegExp(".*/authentication/login"), mockAPI.authentication.login),
......
......@@ -17,7 +17,7 @@ global.console = {
beforeAll(() => {
window.SERVER_ADDRESS = '';
window.API_BASE_ENDPOINT = '/ccce-api';
window.API_BASE_ENDPOINT = '/api/spec';
window.TOKEN_RENEW_INTERVAL=180000;
// Enable the mocking in tests.
server.listen({onUnhandledRequest: "warn"})
......
......@@ -25,7 +25,7 @@ export function AboutView() {
<Paper className={classes.paper}>
<Typography variant="body1">
This is the <Link href="https://confluence.esss.lu.se/x/CVGQFg" target="_blank" rel="noreferrer">beta</Link> version of the deployment part of the CCDB ecosystem (working name CCCE). It is a tool that manages IOCs on host machines, using Ansible to perform the necessary configuration management. This tool will set up IOC-hosts and deploy IOC(s) in a consistent manner, and will configure all necessary services towards this purpose. The tool also integrates with various other systems to enable monitoring of IOCs and hosts, and enables some limited remote execution features. Please note that this is a developmental version, and that
This is the <Link href="https://confluence.esss.lu.se/x/CVGQFg" target="_blank" rel="noreferrer">final</Link> version of the deployment part of the CCDB ecosystem (working name CE deployment). It is a tool that manages IOCs on host machines, using Ansible to perform the necessary configuration management. This tool will set up IOC-hosts and deploy IOC(s) in a consistent manner, and will configure all necessary services towards this purpose. The tool also integrates with various other systems to enable monitoring of IOCs and hosts, and enables some limited remote execution features. Please note that this is a developmental version, and that
<ol>
<li>we do not guarantee data (about deployments) to persist</li>
<li>we offer only minimal support</li>
......@@ -39,7 +39,7 @@ export function AboutView() {
<p>Users without access can only access a subset of the features of the application.</p>
<p>If you wish to visualise or interact directly with the REST API, you can use the <Link
href={`${window.SERVER_ADDRESS}${window.API_BASE_ENDPOINT}.html`} target="_blank" rel="noreferrer">Swagger UI</Link>.</p>
href={`${window.SERVER_ADDRESS}${window.SWAGGER_UI_URL}`} target="_blank" rel="noreferrer">Swagger UI</Link>.</p>
<hr />
......
......@@ -31,7 +31,7 @@ export function HelpView() {
<li>have your IOC in a ESS Gitlab repository in the <Link href="https://gitlab.esss.lu.se/iocs" target="_blank" rel="noreferrer">IOCs</Link> group (you can use <Link href="https://gitlab.esss.lu.se/ics-cookiecutter/cookiecutter-e3-ioc" target="_blank" rel="noreferrer">cookiecutter</Link> to create the repository, or you can create it by hand - you can find an example IOC repository <Link href="https://gitlab.esss.lu.se/ccce/dev/e3-ioc-ccce-example" target="_blank" rel="noreferrer">here</Link>)</li>
<li>have an IOC host registered in <Link href="https://csentry.esss.lu.se/" target="_blank" rel="noreferrer">CSEntry</Link> (physical or virtual).</li>
</ul>
Deployments shall be done on blank (formatted) machines set up with CSEntry - some configuration is done during OS installation. Deployments made on old hosts, or hosts which make use mixed deployment methods (e.g. with both manually and CCCE-deployed IOCs) are not supported by the CCCE team.
Deployments shall be done on blank (formatted) machines set up with CSEntry - some configuration is done during OS installation. Deployments made on old hosts, or hosts which make use mixed deployment methods (e.g. with both manually and CE-deployed IOCs) are not supported by the CE team.
Note that we currently only support deployments on CentOS 7.</p>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment