This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Enable Wake-on-LAN | |
After=network-online.target | |
Wants=network-online.target | |
[Service] | |
Type=oneshot | |
ExecStart=/bin/bash -c 'for i in {1..5}; do /sbin/ethtool -s <NETWORK_DRIVER> wol g && exit 0; sleep 2; done; exit 1' >> /var/log/wol.log 2>&1 | |
RemainAfterExit=yes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
openapi: 3.0.0 | |
info: | |
title: Hackernews API | |
description: An API to interact with Hackernews data. | |
version: 1.0.0 | |
servers: | |
- url: https://hacker-news.firebaseio.com/v0 | |
description: Main API server | |
paths: | |
/topstories.json: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### | |
# HOW TO RUN | |
# install packages: pyspark, click | |
# Submit the spark job: | |
# ex: | |
# spark-submit pyspark-generate-ddl.py --file_path sample_data.parquet --format parquet --table_name sample_table --table_loc s3://it_works/thanks_god/sample_table | |
## | |
import click | |
from pyspark.sql import SparkSession |