Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(redirects): Generating redirects #223

Merged
merged 4 commits into from
Sep 11, 2024
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
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ jobs:
cache: npm
- name: Run Antora
run: ./buildw
- name: Add static resources
run: cp -fr ./static/. ./build/site/
- name: PR Number
run: echo "PR-${{ github.event.pull_request.number }}"
- name: Deploy PR Preview
Expand Down
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

# 🚧 Repository Archived 🚧

**NOTE:** This repository and its contents are no longer actively maintained and have been moved to the [Developer resources repository](https://github.com/teradata/developer-resources) 🛠️


# Teradata Vantage Getting Started Guides

Tutorials for learning the Teradata Vantage database. The documents use the AsciiDoc format. The website is built with Antora.
Expand Down
91 changes: 91 additions & 0 deletions generate-redirects.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
const fs = require('fs');
const path = require('path');

// JSON data
const data = {
"index.html": "https://developers.teradata.com/quickstarts/",
"teradata-vantage-engine-architecture-and-concepts.html": "https://developers.teradata.com/quickstarts/introduction/teradata-vantage-engine-architecture-and-concepts/",
"getting.started.vmware.html": "https://developers.teradata.com/quickstarts/get-access-to-vantage/on-your-local/getting-started-vmware/",
"getting.started.vbox.html": "https://developers.teradata.com/quickstarts/get-access-to-vantage/on-your-local/getting-started-vbox/",
"getting.started.utm.html": "https://developers.teradata.com/quickstarts/get-access-to-vantage/on-your-local/run-vantage-express-on-utm/",
"run-vantage-express-on-aws.html": "https://developers.teradata.com/quickstarts/get-access-to-vantage/on-your-cloud-infrastructure/run-vantage-express-on-aws/",
"vantage.express.gcp.html": "https://developers.teradata.com/quickstarts/get-access-to-vantage/on-your-cloud-infrastructure/vantage-express-gcp/",
"run-vantage-express-on-microsoft-azure.html": "https://developers.teradata.com/quickstarts/get-access-to-vantage/on-your-cloud-infrastructure/run-vantage-express-on-microsoft-azure/",
"getting-started-with-csae.html": "https://developers.teradata.com/quickstarts/get-access-to-vantage/clearscape-analytics-experience/getting-started-with-csae/",
"install-teradata-studio-on-mac-m1-m2.html": "https://developers.teradata.com/quickstarts/connect-to-vantage/install-teradata-studio-on-mac-m1-m2/",
"other-integrations/configure-a-teradata-vantage-connection-in-dbeaver.html": "https://developers.teradata.com/quickstarts/connect-to-vantage/configure-a-teradata-vantage-connection-in-dbeaver/",
"odbc.ubuntu.html": "https://developers.teradata.com/quickstarts/connect-to-vantage/configure-odbc/ubuntu/",
"nos.html": "https://developers.teradata.com/quickstarts/manage-data/nos/",
"select-the-right-data-ingestion-tools-for-teradata-vantage.html": "https://developers.teradata.com/quickstarts/manage-data/select-the-right-data-ingestion-tools-for-teradata-vantage/",
"airflow.html": "https://developers.teradata.com/quickstarts/manage-data/airflow/",
"dbt.html": "https://developers.teradata.com/quickstarts/manage-data/dbt/",
"advanced-dbt.html": "https://developers.teradata.com/quickstarts/manage-data/advanced-dbt/",
"modelops/using-feast-feature-store-with-teradata-vantage.html": "https://developers.teradata.com/quickstarts/manage-data/using-feast-feature-store-with-teradata-vantage/",
"other-integrations/getting.started.dbt-feast-teradata-pipeline.html": "https://developers.teradata.com/quickstarts/manage-data/getting-started-dbt-feast-teradata-pipeline/",
"elt/use-airbyte-to-load-data-from-external-sources-to-teradata-vantage.html": "https://developers.teradata.com/quickstarts/manage-data/use-airbyte-to-load-data-from-external-sources-to-teradata-vantage/",
"elt/terraform-airbyte-provider.html": "https://developers.teradata.com/quickstarts/manage-data/terraform-airbyte-provider/",
"elt/transforming-external-data-loaded-via-airbyte-in-teradata-vantage-using-dbt.html": "https://developers.teradata.com/quickstarts/manage-data/transforming-external-data-loaded-via-airbyte-in-teradata-vantage-using-dbt/",
"tools-and-utilities/run-bulkloads-efficiently-with-teradata-parallel-transporter.html": "https://developers.teradata.com/quickstarts/manage-data/run-bulkloads-efficiently-with-teradata-parallel-transporter/",
"create-parquet-files-in-object-storage.html": "https://developers.teradata.com/quickstarts/manage-data/create-parquet-files-in-object-storage/",
"other-integrations/execute-airflow-workflows-that-use-dbt-with-teradata-vantage.html": "https://developers.teradata.com/quickstarts/manage-data/execute-airflow-workflows-that-use-dbt-with-teradata-vantage/",
"cloud-guides/integrate-teradata-vantage-to-salesforce-using-amazon-appflow.html": "https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-to-salesforce-using-amazon-appflow/",
"segment.html": "https://developers.teradata.com/quickstarts/manage-data/segment/",
"cloud-guides/connect-azure-data-share-to-teradata-vantage.html": "https://developers.teradata.com/quickstarts/manage-data/connect-azure-data-share-to-teradata-vantage/",
"cloud-guides/integrate-teradata-vantage-with-google-cloud-data-catalog.html": "https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-with-google-cloud-data-catalog/",
"other-integrations/configure-a-teradata-vantage-connection-in-datahub.html": "https://developers.teradata.com/quickstarts/manage-data/configure-a-teradata-vantage-connection-in-datahub/",
"jdbc.html": "https://developers.teradata.com/quickstarts/create-applications/jdbc/",
"teradatasql.html": "https://developers.teradata.com/quickstarts/create-applications/teradatasql/",
"mule.jdbc.example.html": "https://developers.teradata.com/quickstarts/create-applications/mule-dbc-example/",
"query-service/send-queries-using-rest-api.html": "https://developers.teradata.com/quickstarts/create-applications/send-queries-using-rest-api/",
"jupyter.html": "https://developers.teradata.com/quickstarts/analyze-data/jupyter/",
"local.jupyter.hub.html": "https://developers.teradata.com/quickstarts/analyze-data/local-jupyter-hub/",
"ml.html": "https://developers.teradata.com/quickstarts/analyze-data/ml/",
"sto.html": "https://developers.teradata.com/quickstarts/analyze-data/sto/",
"perform-time-series-analysis-using-teradata-vantage.html": "https://developers.teradata.com/quickstarts/analyze-data/perform-time-series-analysis-using-teradata-vantage/",
"modelops/deploy-and-monitor-machine-learning-models-with-teradata-modelops-and-byom.html": "https://developers.teradata.com/quickstarts/analyze-data/deploy-and-monitor-machine-learning-models-with-teradata-modelops-and-byom/",
"modelops/deploy-and-monitor-machine-learning-models-with-teradata-modelops-and-git.html": "https://developers.teradata.com/quickstarts/analyze-data/deploy-and-monitor-machine-learning-models-with-teradata-modelops-and-git/",
"modelops/execute-airflow-workflows-with-clearscape-analytics-modelops-model-factory-solution.html": "https://developers.teradata.com/quickstarts/analyze-data/execute-airflow-workflows-with-clearscape-analytics-modelops-model-factory-solution/",
"cloud-guides/sagemaker-with-teradata-vantage.html": "https://developers.teradata.com/quickstarts/analyze-data/sagemaker-with-teradata-vantage/",
"cloud-guides/use-teradata-vantage-with-azure-machine-learning-studio.html": "https://developers.teradata.com/quickstarts/analyze-data/use-teradata-vantage-with-azure-machine-learning-studio/",
"cloud-guides/integrate-teradata-jupyter-extensions-with-google-vertex-ai.html": "https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-google-vertex-ai/",
"cloud-guides/integrate-teradata-jupyter-extensions-with-sagemaker.html": "https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-sagemaker/",
"business-intelligence/create-stunning-visualizations-in-power-bi-using-data-from-teradata-vantage.html": "https://developers.teradata.com/quickstarts/analyze-data/create-stunning-visualizations-in-power-bi-using-data-from-teradata-vantage/",
"other-integrations/integrate-teradata-vantage-with-knime.html": "https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-vantage-with-knime/",
"getting-started-with-vantagecloud-lake.html": "https://developers.teradata.com/quickstarts/vantagecloud-lake/getting-started-with-vantagecloud-lake/",
"vantagecloud-lake/vantagecloud-lake-demo-jupyter-docker.html": "https://developers.teradata.com/quickstarts/vantagecloud-lake/vantagecloud-lake-demo-jupyter-docker/",
"vantagecloud-lake/vantagecloud-lake-demos-visual-studio-code.html": "https://developers.teradata.com/quickstarts/vantagecloud-lake/vantagecloud-lake-demos-visual-studio-code/",
"vantagecloud-lake/vantagecloud-lake-demo-jupyter-sagemaker.html": "https://developers.teradata.com/quickstarts/vantagecloud-lake/vantagecloud-lake-demo-jupyter-sagemaker/",
"vantagecloud-lake/vantagecloud-lake-demo-jupyter-google-cloud-vertex-ai.html": "https://developers.teradata.com/quickstarts/vantagecloud-lake/vantagecloud-lake-demo-jupyter-google-cloud-vertex-ai/",
"vantagecloud-lake/vantagecloud-lake-demo-jupyter-azure.html": "https://developers.teradata.com/quickstarts/vantagecloud-lake/vantagecloud-lake-demo-jupyter-azure/"
};

// Template generator function
function generateHTML(url) {
return `<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="${url}">
<script>location="${url}"</script>
<meta http-equiv="refresh" content="0; url=${url}">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="${url}">${url}</a>.</p>`;
}

// Directory where the files will be saved
const outputDir = path.join(__dirname, 'static');
if (!fs.existsSync(outputDir)) {
fs.mkdirSync(outputDir);
}

// Loop through the JSON data
Object.keys(data).forEach(fileName => {
const url = data[fileName];
const htmlContent = generateHTML(url);

// Write the HTML content to a file
const filePath = path.join(outputDir, fileName);
fs.writeFileSync(filePath, htmlContent, { recursive: true, encoding: 'utf-8' });

console.log(`File created: ${filePath}`);
});
9 changes: 9 additions & 0 deletions static/advanced-dbt.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/manage-data/advanced-dbt/">
<script>location="https://developers.teradata.com/quickstarts/manage-data/advanced-dbt/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/manage-data/advanced-dbt/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/manage-data/advanced-dbt/">https://developers.teradata.com/quickstarts/manage-data/advanced-dbt/</a>.</p>
9 changes: 9 additions & 0 deletions static/airflow.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/manage-data/airflow/">
<script>location="https://developers.teradata.com/quickstarts/manage-data/airflow/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/manage-data/airflow/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/manage-data/airflow/">https://developers.teradata.com/quickstarts/manage-data/airflow/</a>.</p>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/analyze-data/create-stunning-visualizations-in-power-bi-using-data-from-teradata-vantage/">
<script>location="https://developers.teradata.com/quickstarts/analyze-data/create-stunning-visualizations-in-power-bi-using-data-from-teradata-vantage/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/analyze-data/create-stunning-visualizations-in-power-bi-using-data-from-teradata-vantage/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/analyze-data/create-stunning-visualizations-in-power-bi-using-data-from-teradata-vantage/">https://developers.teradata.com/quickstarts/analyze-data/create-stunning-visualizations-in-power-bi-using-data-from-teradata-vantage/</a>.</p>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/manage-data/connect-azure-data-share-to-teradata-vantage/">
<script>location="https://developers.teradata.com/quickstarts/manage-data/connect-azure-data-share-to-teradata-vantage/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/manage-data/connect-azure-data-share-to-teradata-vantage/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/manage-data/connect-azure-data-share-to-teradata-vantage/">https://developers.teradata.com/quickstarts/manage-data/connect-azure-data-share-to-teradata-vantage/</a>.</p>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-google-vertex-ai/">
<script>location="https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-google-vertex-ai/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-google-vertex-ai/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-google-vertex-ai/">https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-google-vertex-ai/</a>.</p>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-sagemaker/">
<script>location="https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-sagemaker/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-sagemaker/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-sagemaker/">https://developers.teradata.com/quickstarts/analyze-data/integrate-teradata-jupyter-extensions-with-sagemaker/</a>.</p>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-to-salesforce-using-amazon-appflow/">
<script>location="https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-to-salesforce-using-amazon-appflow/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-to-salesforce-using-amazon-appflow/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-to-salesforce-using-amazon-appflow/">https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-to-salesforce-using-amazon-appflow/</a>.</p>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-with-google-cloud-data-catalog/">
<script>location="https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-with-google-cloud-data-catalog/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-with-google-cloud-data-catalog/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-with-google-cloud-data-catalog/">https://developers.teradata.com/quickstarts/manage-data/integrate-teradata-vantage-with-google-cloud-data-catalog/</a>.</p>
9 changes: 9 additions & 0 deletions static/cloud-guides/sagemaker-with-teradata-vantage.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/analyze-data/sagemaker-with-teradata-vantage/">
<script>location="https://developers.teradata.com/quickstarts/analyze-data/sagemaker-with-teradata-vantage/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/analyze-data/sagemaker-with-teradata-vantage/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/analyze-data/sagemaker-with-teradata-vantage/">https://developers.teradata.com/quickstarts/analyze-data/sagemaker-with-teradata-vantage/</a>.</p>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/analyze-data/use-teradata-vantage-with-azure-machine-learning-studio/">
<script>location="https://developers.teradata.com/quickstarts/analyze-data/use-teradata-vantage-with-azure-machine-learning-studio/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/analyze-data/use-teradata-vantage-with-azure-machine-learning-studio/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/analyze-data/use-teradata-vantage-with-azure-machine-learning-studio/">https://developers.teradata.com/quickstarts/analyze-data/use-teradata-vantage-with-azure-machine-learning-studio/</a>.</p>
9 changes: 9 additions & 0 deletions static/create-parquet-files-in-object-storage.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<meta charset="utf-8">
<link rel="canonical" href="https://developers.teradata.com/quickstarts/manage-data/create-parquet-files-in-object-storage/">
<script>location="https://developers.teradata.com/quickstarts/manage-data/create-parquet-files-in-object-storage/"</script>
<meta http-equiv="refresh" content="0; url=https://developers.teradata.com/quickstarts/manage-data/create-parquet-files-in-object-storage/">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://developers.teradata.com/quickstarts/manage-data/create-parquet-files-in-object-storage/">https://developers.teradata.com/quickstarts/manage-data/create-parquet-files-in-object-storage/</a>.</p>
Loading